Skip to content

Commit f86aeeb

Browse files
committed
up the threshold for partial bezier path generation
1 parent 348e0cf commit f86aeeb

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/path.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ pub fn generate_bezier_path(
2323
let dx = end_x - start_x;
2424
let dy = end_y - start_y;
2525
let dist_sq = dx * dx + dy * dy;
26-
let threshold = 10.0 * zoom;
26+
let threshold = 20.0 * zoom;
2727

2828
if dist_sq < threshold * threshold {
2929
return format!("M {} {} L {} {}", start_x, start_y, end_x, end_y);
@@ -86,7 +86,7 @@ pub fn generate_partial_bezier_path(
8686
let dx_full = end_x - start_x;
8787
let dy_full = end_y - start_y;
8888
let dist_sq = dx_full * dx_full + dy_full * dy_full;
89-
let threshold = 10.0 * zoom;
89+
let threshold = 20.0 * zoom;
9090

9191
if dist_sq < threshold * threshold {
9292
let curr_x = start_x + dx_full * t;

0 commit comments

Comments
 (0)