Hi James, On 10/11/07, James Dickson <[EMAIL PROTECTED]> wrote: > > Hi, > > I have a quick question about reading and writing files using OSG. I have > read the tutorial about reading files, but I would like to be able to read > my own file format by maybe writing the necessary plugin. Could someone > point me in the direction of how I might be able to do this? >
The best way to find how plugins work is to directly look at them. In the source (src\osgPlugins\) you'll find that each plugins implements a Reader Writer class. To make your own plugin you'll need to do the same thing. Secondly I want to be able to write to an alias wavefront .OBJ file. I > understand again from the reading files tutorial that a plugin for this > exists, but do I need to somehow specify that this plugin should be used? > Could someone maybe give a little example of writing to a file? > You don't need to specify it, it will be dynamically loaded if you try to read or write a file with the .obj extension. But take care that some plugins can only read and not write. The best way to know if you can write files with a plugin is to look at its code and check if the writeNode method is implemented. Thank you for any help, > James > > -- > James Dickson > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > -- Serge Lages http://www.tharsis-software.com
_______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

