From 7b9cd50eaa493735048affa8b0732ba50db3b89c Mon Sep 17 00:00:00 2001 From: Whiteaxe Date: Sun, 10 Sep 2023 03:11:57 +0000 Subject: [PATCH] Slightly reduce quad size for map tiles --- src/graphics/primitives/tiles/instance.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/graphics/primitives/tiles/instance.rs b/src/graphics/primitives/tiles/instance.rs index c64c1202..a07a5d67 100644 --- a/src/graphics/primitives/tiles/instance.rs +++ b/src/graphics/primitives/tiles/instance.rs @@ -37,7 +37,8 @@ struct Instance { const TILE_QUAD: Quad = Quad::new( egui::Rect::from_min_max(egui::pos2(0., 0.), egui::pos2(32., 32.0)), - egui::Rect::from_min_max(egui::pos2(0., 0.), egui::pos2(32., 32.0)), + // slightly smaller than 32x32 to reduce bleeding from adjacent pixels in the atlas + egui::Rect::from_min_max(egui::pos2(0.01, 0.01), egui::pos2(31.99, 31.99)), 0.0, );