summaryrefslogtreecommitdiffstats
path: root/packages/svgbob/src
diff options
context:
space:
mode:
authorJovansonlee Cesar <ivanceras@gmail.com>2022-09-25 22:55:22 +0800
committerJovansonlee Cesar <ivanceras@gmail.com>2022-09-25 22:55:22 +0800
commitf17f6b2905d79f85167e88be007d8f4bbbd17044 (patch)
treed093798bb2b48cd3767b1d6c685c2c9f167f73a2 /packages/svgbob/src
parent54931b28665b9cd0541eda84feb03fd7d2b9b935 (diff)
fix: localize points to bottom_half and right_half of HALF_ARCS
Diffstat (limited to 'packages/svgbob/src')
-rw-r--r--packages/svgbob/src/map/circle_map.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/packages/svgbob/src/map/circle_map.rs b/packages/svgbob/src/map/circle_map.rs
index 7f9e4f0..e7000f2 100644
--- a/packages/svgbob/src/map/circle_map.rs
+++ b/packages/svgbob/src/map/circle_map.rs
@@ -691,11 +691,17 @@ lazy_static! {
let span_left_half = span.extract(bounds_left_half.0, bounds_left_half.1).localize();
let span_right_half = span.extract(bounds_right_half.0, bounds_right_half.1).localize();
+ let bottom_half_start = bounds_bottom_half.0.localize_point(p3);
+ let bottom_half_end = bounds_bottom_half.0.localize_point(p1);
+
+ let right_half_start = bounds_right_half.0.localize_point(p4);
+ let right_half_end = bounds_right_half.0.localize_point(p2);
+
let arc_top_half = Arc::new(p1, p3, radius);
- let arc_bottom_half = Arc::new(p3, p1, radius);
+ let arc_bottom_half = Arc::new(bottom_half_start, bottom_half_end, radius);
let arc_left_half = Arc::new(p2, p4, radius);
- let arc_right_half = Arc::new(p4, p2, radius);
+ let arc_right_half = Arc::new(right_half_start, right_half_end, radius);
let diameter = circle_art.diameter();
(diameter,