Package foundry.veil.api.client.ui.util
Class ScissorStack
java.lang.Object
foundry.veil.api.client.ui.util.ScissorStack
A utility class to manage scissor clipping regions.
This allows for restricting rendering to specific rectangular areas.
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
ScissorStack
public ScissorStack()
-
-
Method Details
-
push
public void push(int x, int y, int width, int height) Pushes a new scissor clipping region onto the stack. The region is automatically constrained by any existing regions on the stack.- Parameters:
x
- The x-coordinate of the top-left corner of the region.y
- The y-coordinate of the top-left corner of the region.width
- The width of the region.height
- The height of the region.
-
pop
public void pop()Removes the top scissor clipping region from the stack. If there are any regions remaining, the previous region is reapplied.
-