Shadowmap clamping?

Started by
2 comments, last by rfterdarc 16 years ago
That image shows quite well what my problem is. I need it to clamp correctly to the edge. Shouldn't: Gl.glTexParameteri(Gl.GL_TEXTURE_2D, Gl.GL_TEXTURE_WRAP_S, Gl.GL_CLAMP_TO_EDGE); Gl.glTexParameteri(Gl.GL_TEXTURE_2D, Gl.GL_TEXTURE_WRAP_T, Gl.GL_CLAMP_TO_EDGE); have done the job? (When set on the shadowmap) /MindWipe
"To some its a six-pack, to me it's a support group."
Advertisement
set the border to whatevre u want it to be
+ use GL_CLAMP_TO_BORDER

glTexParameterfv( texture_target, GL_TEXTURE_BORDER_COLOR, VEC4(1,1,1,1));
Quote:Original post by zedz
set the border to whatevre u want it to be
+ use GL_CLAMP_TO_BORDER

glTexParameterfv( texture_target, GL_TEXTURE_BORDER_COLOR, VEC4(1,1,1,1));


Thanks! I noticed the problem was actualy just that the border of the shadow map were not completely dark.

"To some its a six-pack, to me it's a support group."
Might want to look into omni shadows maps; rendering the shadow map to a cube map to get shadows in all directions :)

This topic is closed to new replies.

Advertisement