summaryrefslogtreecommitdiff
path: root/lib/api
diff options
context:
space:
mode:
authorKaalleen <36401965+kaalleen@users.noreply.github.com>2024-03-26 07:10:40 +0100
committerGitHub <noreply@github.com>2024-03-26 07:10:40 +0100
commit8e70f3d2feaab8a14f775a5ef84002bdab9688f0 (patch)
treef34d46ead8eb8d15317dc98de4113ccaf8acd0e9 /lib/api
parentea394f6d3b7de3bc0818b6a9921f64e8bcbc4fbf (diff)
Add object based min stitch length (#2792)
* add object based min stitch length (overwrites global) * add object based minimum jump stitch (overwrites global) * rename patches to stitch_groups
Diffstat (limited to 'lib/api')
-rw-r--r--lib/api/stitch_plan.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/api/stitch_plan.py b/lib/api/stitch_plan.py
index 5e9a57c1..0267a70a 100644
--- a/lib/api/stitch_plan.py
+++ b/lib/api/stitch_plan.py
@@ -20,8 +20,8 @@ def get_stitch_plan():
metadata = g.extension.get_inkstitch_metadata()
collapse_len = metadata['collapse_len_mm']
min_stitch_len = metadata['min_stitch_len_mm']
- patches = g.extension.elements_to_stitch_groups(g.extension.elements)
- stitch_plan = stitch_groups_to_stitch_plan(patches, collapse_len=collapse_len, min_stitch_len=min_stitch_len)
+ stitch_groups = g.extension.elements_to_stitch_groups(g.extension.elements)
+ stitch_plan = stitch_groups_to_stitch_plan(stitch_groups, collapse_len=collapse_len, min_stitch_len=min_stitch_len)
return jsonify(stitch_plan)
except InkstitchException as exc:
return jsonify({"error_message": str(exc)}), 500