LLScreenClipRect::LLScreenClipRect(const LLRect& rect, BOOL enabled) : mScissorState(enabled), mEnabled(enabled), mRootScissorRect(gGL.getScissor()) { if (mEnabled) { pushClipRect(rect); } }
LLScreenClipRect::LLScreenClipRect(const LLRect& rect, BOOL enabled) : mScissorState(GL_SCISSOR_TEST), mEnabled(enabled) { if (mEnabled) { pushClipRect(rect); mScissorState.setEnabled(!sClipRectStack.empty()); updateScissorRegion(); } }
void pushClipRect(Vector2i pos, Vector2u size) { pushClipRect(pos.x, pos.y, size.x, size.y); }