I think all that what's going on is that the loader is simply assigning the image maps (diffuse and specular) to various texture unit numbers: http://trac.openscenegraph.org/projects/osg//browser/OpenSceneGraph/trunk/src/osgPlugins/obj/ReaderWriterOBJ.cpp?rev=13006#L67 http://trac.openscenegraph.org/projects/osg//browser/OpenSceneGraph/trunk/src/osgPlugins/obj/ReaderWriterOBJ.cpp?rev=13006#L835
but it doesn't really set up a shader or anything special to utilize them, so the specular texture just clobbers the diffuse texture. You most likely need to write a small fragment shader to actually interpret the maps in whatever way you want. On Mon, Sep 18, 2017 at 2:10 AM, Ralf Habacker <[email protected]> wrote: > Hi, > > we tried to use the obj plugin in an osg based vr application for the > HTC Vive to load the steamvr controller (which is provided as .obj file) > and recognized that it is displayed with black surfaces instead of > showing the provided textures (which works for example in blender). > > We found out that the osg plugin shows always black surfaces if a > material used by an obj file contains a diffuse *and* a specular texture > which could be verified with the appended test case. > > Are there any hints how to solve this issue ? > > Regards > Ralf > > > > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > -- Chris 'Xenon' Hanson, omo sanza lettere. [email protected] http://www.alphapixel.com/ Training • Consulting • Contracting 3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 • GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL Legal/IP • Forensics • Imaging • UAVs • GIS • GPS • osgEarth • Terrain • Telemetry • Cryptography • LIDAR • Embedded • Mobile • iPhone/iPad/iOS • Android @alphapixel <https://twitter.com/alphapixel> facebook.com/alphapixel (775) 623-PIXL [7495]
_______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

