Cleanup: GPU: Encapsulate scissor test

This commit is contained in:
2020-07-17 19:21:33 +02:00
parent d19b3019d9
commit 1f2edba1fb
6 changed files with 19 additions and 9 deletions

View File

@@ -146,6 +146,16 @@ void GPU_program_point_size(bool enable)
}
}
void GPU_scissor_test(bool enable)
{
if (enable) {
glEnable(GL_SCISSOR_TEST);
}
else {
glDisable(GL_SCISSOR_TEST);
}
}
void GPU_scissor(int x, int y, int width, int height)
{
glScissor(x, y, width, height);