Hi Christion,

you could use a switch above the 2 geometries or different cullmasks for the geodes and control it via the cameras cullmask/setting the switch before culling
Hey all,

I have a shadowed scene that hosts a detailed city model and some 15000 objects using instanced geometry that also casts shadows. The instance positions are provided through a 2D float texture (128x128) to the vertex shader.

To reduce the render times I was thinking that I should maybe replace the geometry of these instanced geometries with something much simpler. My shadow resolution is coarse and observers likely wouldn't notice the difference.

Could it be a good idea to install a NodeCallback on the instanced geometry that replaces the Geometry of the geode with a cube while we're in the shadow camera pass, and reinstalls the original object when we're in the main camera pass? If possible I would like to avoid the overhead of having a second instanced geometry for just the shadow casters, as updating this 128x128 comes with some costs - and simply swapping out the geometry should accomplish that.

Christian



_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to