From ebdfe1ab7d7a3b73346885c635e98b2021921010 Mon Sep 17 00:00:00 2001 From: Jabier Arraiza Cenoz Date: Wed, 30 Jul 2014 02:36:53 +0200 Subject: Fix a bug pointed by su_v on fillet-chamfer open paths (bzr r13341.1.109) --- src/live_effects/lpe-fillet-chamfer.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/live_effects/lpe-fillet-chamfer.cpp b/src/live_effects/lpe-fillet-chamfer.cpp index eae37ad36..1dffba1bf 100644 --- a/src/live_effects/lpe-fillet-chamfer.cpp +++ b/src/live_effects/lpe-fillet-chamfer.cpp @@ -517,6 +517,8 @@ LPEFilletChamfer::doEffect_path(std::vector const &path_in) counter - counterCurves, filletChamferData[counter - counterCurves][X]), &intpart); + } else if (!path_it->closed() && curve_it2 == curve_endit){ + time_it2 = 0; } else { time_it2 = modf(fillet_chamfer_values.to_time( counter + 1, filletChamferData[counter + 1][X]), @@ -529,6 +531,8 @@ LPEFilletChamfer::doEffect_path(std::vector const &path_in) it1_length + fillet_chamfer_values.to_len( counter - counterCurves, filletChamferData[counter - counterCurves][X]); + } else if (!path_it->closed() && curve_it2 == curve_endit){ + resultLenght = 0; } else { resultLenght = it1_length + fillet_chamfer_values.to_len( @@ -607,6 +611,8 @@ LPEFilletChamfer::doEffect_path(std::vector const &path_in) int type = 0; if(path_it->closed() && curve_it2 == curve_endit){ type = abs(filletChamferData[counter - counterCurves][Y]); + } else if (!path_it->closed() && curve_it2 == curve_endit){ + //0 } else { type = abs(filletChamferData[counter + 1][Y]); } -- cgit v1.2.3