Hi,

I've been working on updating our shaders to remove the deprecated built-ins. 
I've gotten stuck on the gl_EyePlanes as used to compute projected shadow 
texture coordinates as follows (same convention as osg-generated shadow 
shaders):


Code:

gl_TexCoord[shadowTextureUnit0].s = dot( ecPosition, 
gl_EyePlaneS[shadowTextureUnit0] );
gl_TexCoord[shadowTextureUnit0].t = dot( ecPosition, 
gl_EyePlaneT[shadowTextureUnit0] );
gl_TexCoord[shadowTextureUnit0].p = dot( ecPosition, 
gl_EyePlaneR[shadowTextureUnit0] );
gl_TexCoord[shadowTextureUnit0].q = dot( ecPosition, 
gl_EyePlaneQ[shadowTextureUnit0] );




I am using the VDSM implementation and passing in the 4 planes as found in 
assignTexGenSettings(...), but they seem to be different than what is actually 
found in the built-ins during shader execution. I am guessing there is some 
sort of modelview transformation happening, but having trouble with it.

Any ideas on how to recreate these planes for passing into the shader would be 
appreciated.

Thanks!

Cheers,
Garrett[/code]

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=57816#57816





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

Reply via email to