Fix 'Offset Path' node crash on empty or zero-scaled geometry
This commit is contained in:
parent
39a7c45ccd
commit
05f6138b65
|
|
@ -45,6 +45,10 @@ pub fn offset_bezpath(bezpath: &BezPath, distance: f64, join: Join, miter_limit:
|
||||||
})
|
})
|
||||||
.collect::<Vec<BezPath>>();
|
.collect::<Vec<BezPath>>();
|
||||||
|
|
||||||
|
if bezpaths.is_empty() {
|
||||||
|
return BezPath::new();
|
||||||
|
}
|
||||||
|
|
||||||
// Clip or join consecutive Subpaths
|
// Clip or join consecutive Subpaths
|
||||||
for i in 0..bezpaths.len() - 1 {
|
for i in 0..bezpaths.len() - 1 {
|
||||||
let j = i + 1;
|
let j = i + 1;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue