Scissor Test

The first additional test you can enable to control fragment visibility is the scissor test. The scissor box is a rectangular portion of your window and restricts all drawing to its region. You specify the scissor box using the glScissor() command, and enable the test by specifying GL_SCISSOR_TEST with glEnable(). If a fragment lies inside the rectangle, it passes the scissor test.

Get OpenGL Programming Guide: The Official Guide to Learning OpenGL, Version 4.3, Eighth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.