diff --git a/crates/transform-gizmo-egui/src/lib.rs b/crates/transform-gizmo-egui/src/lib.rs index 666b5ca..a99247a 100644 --- a/crates/transform-gizmo-egui/src/lib.rs +++ b/crates/transform-gizmo-egui/src/lib.rs @@ -96,7 +96,7 @@ impl GizmoExt for Gizmo { let draw_data = self.draw(); - ui.painter().with_clip_rect(egui_viewport).add(Mesh { + egui::Painter::new(ui.ctx().clone(), ui.layer_id(), egui_viewport).add(Mesh { indices: draw_data.indices, vertices: draw_data .vertices