fix(wire_gpu): correct offset calculation for wire midpoint positioning

This commit is contained in:
Hakan Seven committed 2026-05-31 10:24:27 +03:00
1 parent 3cf21c1cc2
commit 9fa33ec7a0
1 file changed
+1 -1
+1 -1
View File
@@ -228,7 +228,7 @@ fn emit_wire_instances(wire: &WireModel, color: [f32; 4], draw_depth: f32) -> Ve
.find(|&v| v > 0.0)
.unwrap_or_else(|| wire.pattern[0].abs());
// Phase that puts the wire midpoint at the dash center.
let offset = first_dash * 0.5 - total * 0.5;
let offset = first_dash * 0.5 + total * 0.5;
for d in dists.iter_mut() {
*d += offset;
}