Draft: Fix misplaced Draft_Edit nodes for BezCurve 2nd version

The poles in the resetTrackersBezier function are in the CS of the geometric parent of the curve. Before using `p = obj.getGlobalPlacement().multVec(p)` the nodes have to be translated to the CS of the curve. Otherwise the effects of the curve's Placement would be added twice. See discussion: https://github.com/FreeCAD/FreeCAD/pull/4889



 the global coordinate system. They should therefore not be translated from the LCS to the GCS.
This commit is contained in:
Roy-043
2021-06-26 09:42:56 +02:00
committed by GitHub
parent 79b41f7393
commit d72f90d972

View File

@@ -595,6 +595,7 @@ class Edit(gui_base_original.Modifier):
pointswithmarkers.append((poles[-1],knotmarkers[knotmarkeri]))
for index, pwm in enumerate(pointswithmarkers):
p, marker = pwm
p = obj.Placement.inverse().multVec(p)
p = obj.getGlobalPlacement().multVec(p)
self.trackers[obj.Name].append(trackers.editTracker(p, obj.Name,
index, obj.ViewObject.LineColor, marker=marker))