what happened to Transform#[]( coords#[] )
Monkey Forums/Monkey Programming/what happened to Transform#[]( coords#[] )
| ||
somewhere along the lines Transform#[]( coords#[] ) disappeared from mojo.graphics. I guess I should now do GetMatrix and do the multiplication myself? speaking of which, can we have an overloaded GetMatrix so that it doesn't have to allocate a new array each time? i.e. GetMatrix( m#[] )? |
| ||
I just checked mojo.graphics and Transform, Translate, Scale, Rotate, InvTransform, GetMatrix and SetMatrix are all there on my computer V63... |
| ||
actually for Transform and GetMatrix 63b only has Transform( m#[] ) Transform( ix#,iy#,jx#,jy#,tx#,ty# ) GetMatrix#[]() graphics.monkey used to have Transform#[]( coords#[] ) as well, but I no longer need it. I'd like to see GetMatrix( m#[] ) added... |
| ||
you could for now just add this to the bottom of mojo.graphics [monkeycode] Function GetMatrix : Void( m : Float[] ) m[ 0 ] = context.ix m[ 1 ] = context.iy m[ 2 ] = context.jx m[ 3 ] = context.jy m[ 4 ] = context.tx m[ 5 ] = context.ty End Function [/monkeycode] |
| ||
yes, that's what I've been doing since the beginning... it's a valuable performance tweak I believe should just be in there especially since we have separate update and render functions. |