diff --git a/epaint/src/tessellator.rs b/epaint/src/tessellator.rs index f46af30d..95fde7f8 100644 --- a/epaint/src/tessellator.rs +++ b/epaint/src/tessellator.rs @@ -695,6 +695,11 @@ impl Tessellator { } } + /// Set the `Rect` to use for culling. + pub fn set_clip_rect(&mut self, clip_rect: Rect) { + self.clip_rect = clip_rect; + } + /// Tessellate a single [`Shape`] into a [`Mesh`]. /// /// * `tex_size`: size of the font texture (required to normalize glyph uv rectangles).