[osg-users] osg 3.3.8 and SAMPLER_2D uniforms

Trajce Nikolov NICK trajce.nikolov.nick at gmail.com
Mon May 4 04:20:06 PDT 2015


Hi Robert,

after I upgraded to 3.3.8 I am experiencing issues with using multiple
textures in a StateSet and setting uniforms. In 3.3.7 all works fine.

The issue:

uniform sampler2D texture; // in the shader

In the code:

_ss->addUniform(new
osg::Uniform(osg::Uniform::SAMPLER_2D,"texture",(int)slot) ...


uniform this causes the model on MacOSX to turn to black on Windows
the model to disappear.


The working code from 3.3.7 (defining it with osg::Uniform::SAMPLER_2D
was not working either)


_ss->addUniform(new osg::Uniform("texture")aoSlot) ...




Any clue?

Thanks a bunch!

-- 
trajce nikolov nick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20150504/02efa170/attachment-0002.htm>


More information about the osg-users mailing list