Hi,
Problem description:
We have a scene with a lot of drawables (>1500). The stateset of the
root of the
scene graph contains a shader program.
When we increase the number of uniform variables used by the shader (the
shader is
not more complex, we create fake uniforms), the application performance
drop down.
A little debugging session after, it appears that for each drawable that
has a stateset
defined, the uniform variables are applied.
They are not really applied, (their modifiedCount has not changed) but the
osg::Program::PerContextProgram (line 163) do a "find" on a std::map
(std::string -> GLint)
to retrieve the uniform location.
It seems that it is this access to the std::map that cause the
performance drop.
Does someone has encountered this problem ?
Is there a way to disable the uniform application for each drawables ?
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/