Hi how would you include glsl shaders in 3ds file, for example? model formats support some limited set of features, and not all of those supported by osg writer plugins.
26.12.2012, 21:24, "Mateo Gasparovic" <[email protected]>: > Hi, > > I've made projecting textures on the STL model. To project textures I've used > the OpenGL vertex and fragment sheders as in examle on Jotschi's Blog: > "ProjectiveTextureExample OpenSceneGraph". > I'm interested if is it possible to save the textured model that is displayed > in the window (viewer) in OBJ, 3DS, PLY, VRML2.0 file? > > When I save a model in OSG file and import it again, everything is OK. My OSG > model file has texture information. If the problem can be solved by > converting the OSG to OBJ, 3DS, PLY or VRML2.0 it's fine as well. > Is there a program, procedure or sample code for such conversion? > > I tried to save node/object file (OBJ) but in both cases I only receive > geometry model > without textures. MTL file is empty. Also, I've tried to export a 3DS or PLY > file, but in both cases I got geometry without textures. > > Below I have attached a part of my code, where I tried to save/export > textured model. > > osgViewer::Viewer viewer; > viewer.setSceneData(createModel3()); > osgDB::writeObjectFile(*viewer.getSceneData(),"test.obj"); > > Thank you for help! > > Best regards, > Mateo Gasparovic > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=51113#51113 > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

