[osg-users] Missing ShapeDrawables in .obj export

Robert Osfield robert.osfield at gmail.com
Wed Nov 25 08:43:46 PST 2009

Hi Ben,

On Wed, Nov 25, 2009 at 4:25 PM, Ben Axelrod <BAxelrod at coroware.com> wrote:
> I understand ShapeDrawable is an osg construct that obj won't understand.  But i was under the impression that the conversion out of the osg format would de-OSG all shapes.  in other words, make a mesh out of the ShapeDrawable. But clearly this is not the case.  Is this feature on the todo list?

It's not on my TODO list.  The OSG is community work, if you have the
itch then feel free to scratch it :-)

As a pointer of how to tackle it I would suggest looking at using a
PrimtiveFunctor/TriangleFunctor to stream out the geometry data from
the drawable.  Have a look at other instances of these functors such
as in src/osgUtil/LineSegmentIntersector.cpp.

> Also, i know that the VRML format has some concept of primitive shapes.  Do you think that the osg to wrl conversion would include the primitive ShapeDrawables?  I would just try it, but unfortunately i did not build osg with vrml writing capabilities, and i won't have the opportunity to rebuild osg for a while.

I'm not up to speed of VRML or the author of the OSG's VRML plugin so
can't answer this specifically.  In general I would say it should be
supportable but have to defer to others who know more about VRML/the
OSG's VRML plugin to comment.


More information about the osg-users mailing list