It turned out that I was not calling osg::Program::addBindAttribLocation to bind "Tangent" to "6". Somehow it worked fine under Linux. Now it works under OS X, too.
2014-06-28 1:58 GMT+07:00 michael kapelko <[email protected]>: > I tried 7, 8, 9. > 8 looked even more broken than before (looked like it was used by some > predefined attribute). > 7 and 9 were (0, 0, 0) again. > > > 2014-06-28 1:34 GMT+07:00 michael kapelko <[email protected]>: > > Here's my wrapper TSGVisitor class: http://goo.gl/Hd0WwJ >> And I use ID=6 for the attribute. >> I'll try 7 and 8. >> >> >> 2014-06-28 1:28 GMT+07:00 Sebastian Messerschmidt < >> [email protected]>: >> >> Hi Michael, >>> >>> can you show the code calling the TSG and assigning the vertex >>> attributes? >>> Usually you will have to to a high vertex attribute like 7 or 8, since >>> the lower numbers are mapped to the fixed function pipeline attributes. >>> I can check my code when I'm on my development machine again. >>> Which version of osg are you using? >>> >>> Cheers >>> Sebastain >>> >>> I've researched deeper into my normal maps not working after fixing >>> those shader errors that have been reported under OS X, and found out that >>> in my pass1VS ( http://goo.gl/sT7m7n ) Tangent attribute is always (0, >>> 0, 0). I get it from osgUtil::TangentSpaceGenerator. >>> Any clues? >>> Thanks. >>> >>> >>> 2014-06-26 17:51 GMT+07:00 Sebastian Messerschmidt < >>> [email protected]>: >>> >>>> Hi Michael, >>>> >>>> The shader code seems indeed to be faulty and I found the errors >>>> generated quite appropriate. Maybe your driver in the Linux is quite sloppy >>>> and uses some extensions. Nvidia for instance allows all sort of >>>> non-standard functions ( hlsl saturate etc.) >>>> I usually use ATI Shader Analyzer. It seems to stick to the GLSL >>>> specifications very tightly [1]. >>>> Unfortunately I'm on vacation and don't have my developer laptop with >>>> me, so I cannot check directly. >>>> >>>> [1] >>>> http://developer.amd.com/tools-and-sdks/graphics-development/gpu-tools/gpu-shaderanalyzer/#download >>>> >>>> Cheers >>>> Sebastian >>>> _______________________________________________ >>>> osg-users mailing list >>>> [email protected] >>>> >>>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org >>>> >>> >>> >>> >>> _______________________________________________ >>> osg-users mailing >>> [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 >>> >>> >> >
_______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

