Hi Simon, Thanks for your advices, but I need to apply unordered rotation. And I don't want to think about rotation apply order. So I can't use direct invert function, rotation should be incremental order, not direct neutralization.
Thanks for your advices again. Regards. Ümit Uzun 2009/12/31 Simon Hammett <s.d.hamm...@googlemail.com> > Not really following what you are after, but one point: > > 2009/12/31 Ümit Uzun <umituzu...@gmail.com> > >> Hi Paul, >> >> Thanks for your reply. I need only one explanation about that; >> >> //////////////////////////////////////////////// psudo code >> Matrix matrix1= identity; >> matrix1->rotate( 10 degree on LOCAL X axis ) >> matrix1->rotate( 10 degree on LOCAL Y axis ) >> matrix1->rotate( -10 degree on LOCAL X axis ) >> matrix1->rotate( -10 degree on LOCAL Y axis ) >> >> matrix1 is NOT IDENTITY at last. >> ///////////////////////////////////////////////// >> > > No it won't be the identity, you've got the undo in the wrong order. > > Matrix matrix1= identity; > > // rotate > > matrix1->rotate( 10 degree on LOCAL X axis ) > matrix1->rotate( 10 degree on LOCAL Y axis ) > > // un-rotate > > matrix1->rotate( -10 degree on LOCAL Y axis ) > matrix1->rotate( -10 degree on LOCAL X axis ) > > ASSERT(matrix1 == identity); > > If you want undo, just use matrix invert, which > will work unless you've got a scale by 0 in the transform. > > -- > http://www.ssTk.co.uk > > _______________________________________________ > osg-users mailing list > osg-users@lists.openscenegraph.org > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > >
_______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org