brettwiesner wrote:
Hey,

Since most DDS textures are going to come in flipped (ie: directX style
and not openGL style) I would like my application to always pass the
"dds_flip" option to the DDS loader. If I could extend the DDS loader I
could do that. Just another case for including the loaders as actual
libs and the plugins themselves as smaller projects that just use the
loaders api.

It's easy enough to hard code a ReaderWriter option:

options = new osgDB::ReaderWriter::Options("dds_flip");
texImage = osgDB::readImageFile(filename, options);


You might want to use a ref_ptr for the options object, but basically, the above should work.

--"J"

I think you're misunderstanding. I'm not loading the texture myself. Other loaders are... the flt loader, the 3ds loader, etc. Surely you don't mean to change all of them to pass that option? I'm actually trying to avoid changing OSG source (otherwise I could just have the DDS loader always use that option).

I'm suggesting two things...

1) that the DDS loader be fixed (ie: DDS is a directX file format and it's coordinate system is directX. OSG should expect that DDS files come in that coordinate system and flip them automatically). 2) And that I should be able to derive MyDdsLoader from a osgDB::ddsLoader and register that with the osgDB_dds plugin so that my loader is used.

Thanks,
Brett
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to