• Popular Now

• 12
• 12
• 9
• 10
• 13

Archived

This topic is now archived and is closed to further replies.

Clip planes and glScissor question

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

Recommended Posts

Hi, I am trying to incorporate two black patches on my screen on the top and the bottom as you would see in movies. Someone suggested to use a scissor box using glScissor. But I am not getting it right. The parameters of glScissor is x, y, width and height, so if I understand it right it should enclose my whole scene in a box which would give me black patches on all 4 sides, right ? But if this is the case it does not happen. Also I was trying to get the same effect using glClipPlane, but if I use the following, whatever value I put instead of 1 in eqn, it clips out everything below y = 0. I know I can move into ortho mode and draw 2 rectangles and move back to perspective. But is there a better way using glScissor or glClipPlane? Thank you.
GLdoube eqn[4] = { 0, 1, 0, 0};
glClipPlane(GL_CLIP_PLANE0, eqn);
[/soure]

<SPAN CLASS=editedby>[edited by - CRACK123 on November 6, 2003 10:40:19 PM]</SPAN>