• Advertisement
Sign in to follow this  

Shadowmap clamping?

This topic is 3593 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

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

Share this post


Link to post
Share on other sites
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));

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
Might want to look into omni shadows maps; rendering the shadow map to a cube map to get shadows in all directions :)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement