Hi Ümit,
the best way is to have a correct model from the beginning, centered and
aligned with the origin, but if it couldn't be done, you would have to make
the geometry child of a transform that would put the mesh at the right place.
Say you had an object displaced 4 units on the X axis from the origin, then
you would create a translation transform of (-4,0,0) and make it parent of
the mesh. Finally you would use that transform in the scene as the real
object.
Alberto
El Viernes 25 Julio 2008ES 09:59:59 Ümit Uzun escribió:
Hi all,
Firstly sorry for simple question, but I can't find related topics on the
web.
How can I change my models's center coordinate? I have lots of components,
I am trying to collect them in one model, and I want to control one part in
it's local coordinate (for example I want to rotate it around z axes on
it's local coordinate.)
But my components default coordinate center is different one by one (for
example: osgviewer sample.osg axes.osg result is
http://img61.imageshack.us/my.php?image=sampletn4.png ). I mean, I want to
control every part of components in their local coordinate center. What
should I do for changing coordinate system and center for every components?
I used MatrixTransform, PositionAttitudeTransform CoordinateSystemNode but
I can't get success.
Thanks, Best Regards.
Umit UZUN
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org