Hi Ümit,
My last question is, I have declared;
uniform sampler2D diffuseTexture;
in my fragment shader, although I didn't bind it to osg::Uniform in my
main application, I can sample my texture from my shader in Unit 0. Do
you think it is weird or not?
You are relying on the value being set to 0 when it's undefined, which
is not reliable. You should set it correctly. But as I said, you can set
it once on the root node of your scene if that's sufficient for you. No
need to set a uniform with the same name and the same value on every
stateset of every model!
J-S
--
______________________________________________________
Jean-Sebastien Guay jean-sebastien.g...@cm-labs.com
http://www.cm-labs.com/
http://whitestar02.webhop.org/
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org