Hi,

Jesper D. Thomsen wrote:
Is it possible to create an ellipsoid from ShapeDrawable(sphere shape) by applying some kind of scaling,
Sure, just put the relevant transform node above the a Geode that holds the ShapeDrawable, i.e.
transform -> Geode -> ShapeDrawable
I thought that maybe there was som kind of ScalingTransform kind of like PositionAttitudeTransform.
Well, there is the general MatrixTransform that you can use to define a transformation using a 4x4 matrix.
For a scale it can be used as (pseudo-code):

mt = new osg::MatrixTransform(osg::Matrix::scale(sx, sy, sz))

Note that ShapeDrawable is indeed nice for quickly generating shapes, but if you want more functionality (specifically texture mapping) it isn't supported by it.

Paul
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to