Hi Danoo,

On 27 March 2013 07:32, Daniel Schmid <[email protected]> wrote:
> The problem is, that in my calculations of my uniform, I need the ViewMatrix
> of the camera in world coordinates. When I get the viewmatrix of the current
> camera (which is the prerender camera) in my cull visitor, it get a identiy
> matrix. I guess this is due to the fact that this camera is child of the
> main camera. How can I calculate the correct ViewMatrix ?

Cast the NodeVisitor passed into the callback to a CullVisitor and
then use the getModelViewMatrix() method to get access to the current
modelview matrix.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to