hi here is the topic terry send me some days ago, i didn't yet found the time to review it, may in the mean time some has time to check it out, and the we can submiss it.
/adegli ---------- Forwarded message ---------- From: Terry Welsh <[EMAIL PROTECTED]> Date: 18.10.2007 23:04 Subject: pssm fix To: Adrian Egli <[EMAIL PROTECTED]> Hey Adrian, I was playing with your shadow code a bit. Things look much better on NVidia if you do two things: 1. Use factor = 1.1 and units = 4.0 2. Comment all of this out of the shader: // sstr << " vec4 random" << i <<" = "<<(1.25/(double)_resolution)<<"*coord.z*texture2D (randomTexture,gl_TexCoord[" << (i+1) <<"].st); " << std::endl; // sstr << " float shadow1" << i <<" = shadow2DProj( shadowTexture" << i <<",gl_TexCoord[" << (i+1) <<"]+random" << i <<".r*vec4(-1,-1,0,0)).r;" << std::endl; // sstr << " float shadow2" << i <<" = shadow2DProj( shadowTexture" << i <<",gl_TexCoord[" << (i+1) <<"]+random" << i <<".g*vec4(1,-1,0,0)).r;" << std::endl; // sstr << " float shadow3" << i <<" = shadow2DProj( shadowTexture" << i <<",gl_TexCoord[" << (i+1) <<"]+random" << i <<".b*vec4(1,1,0,0)).r;" << std::endl; // sstr << " float shadow4" << i <<" = shadow2DProj( shadowTexture" << i <<",gl_TexCoord[" << (i+1) <<"]+random" << i <<".a*vec4(-1,1,0,0)).r;" << std::endl; // sstr << " shadow" << i <<" = shadow" << i <<" + shadow1" << i <<" + shadow2" << i <<" + shadow3" << i <<" + shadow4" << i <<";" << std::endl; // sstr << " shadow" << i <<" = shadow" << i <<"*0.2;" << std::endl; -- Terry Welsh - mogumbo 'at' gmail.com www.reallyslick.com | www.mogumbo.com -- ******************************************** Adrian Egli
_______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org