Hi J-S,

On Wed, Apr 16, 2008 at 6:25 PM, Jean-Sébastien Guay
<[EMAIL PROTECTED]> wrote:
>  Well, yes, that resolves that specific problem. But what if I was using
>  view-dependent shadow mapping, or reflection mapping (as I said with the
>  cow example), or other similar view-dependent effects... We'll see the
>  same problem, and the techniques are by definition view-dependent so
>  switching to a world space effect is not an option.
>
>  That's why I'm looking to put the main camera's view matrix in a
>  uniform, and then using it in the shader.

The main cameras view matrix could be added as an extra uniform, the
main cameras projection matrix too?

However. one will have to careful about all of this, if you need
something to be the same across all cameras then it really needs to be
in world coordinates, this way all cameras will get the same value for
it, so if you are getting problem perhaps it suggests that something
else needs to be tweaked along the way w.r.t the algorithm.  This is
in effect what I was talking about when suggest the use of position
lighting source rather than a directional one.

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

Reply via email to