From 2d37f1a778712c6683908c20f1bcdc8b7cf411b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C4=93teris=20Pakalns?= Date: Thu, 6 Feb 2025 22:37:32 +0200 Subject: [PATCH] Fix panic when rendering thin textured rectangles (#5692) * Closes https://github.com/emilk/egui/issues/5664 * [x] I have followed the instructions in the PR template (cherry picked from commit 54d00d7d6990dab35b4ec8083d08b42d247c952a) --- crates/epaint/src/tessellator.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/epaint/src/tessellator.rs b/crates/epaint/src/tessellator.rs index e8f8ad52c..6d953f257 100644 --- a/crates/epaint/src/tessellator.rs +++ b/crates/epaint/src/tessellator.rs @@ -1810,7 +1810,7 @@ impl Tessellator { } } - if stroke.is_empty() { + if stroke.is_empty() && out.texture_id == TextureId::default() { // Approximate thin rectangles with line segments. // This is important so that thin rectangles look good. if rect.width() <= 2.0 * self.feathering {