From: Marko Luukkainen Date: Tue, 16 Jul 2019 12:28:11 +0000 (+0300) Subject: Turn component calculation with offset vector fixed X-Git-Tag: v1.43.0~251 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=f4b2a4e52c691c1fe95f1a8b28cace8718115994;p=simantics%2F3d.git Turn component calculation with offset vector fixed gitlab #12 Change-Id: Iac7b2676a2f189db135f81fe24420912f994bf9b --- diff --git a/org.simantics.plant3d/src/org/simantics/plant3d/scenegraph/controlpoint/PipingRules.java b/org.simantics.plant3d/src/org/simantics/plant3d/scenegraph/controlpoint/PipingRules.java index 8cbe5a8a..606479ad 100644 --- a/org.simantics.plant3d/src/org/simantics/plant3d/scenegraph/controlpoint/PipingRules.java +++ b/org.simantics.plant3d/src/org/simantics/plant3d/scenegraph/controlpoint/PipingRules.java @@ -1011,7 +1011,7 @@ public class PipingRules { a = updateTurnControlPointTurn(u.start, startPrev, u.end); } else { Vector3d ep = new Vector3d(u.endPoint); - ep.add(u.offset); + ep.sub(u.offset); a = updateTurnControlPointTurn(u.start, u.startPoint, startPrev.getPosition(), ep); } @@ -1036,7 +1036,7 @@ public class PipingRules { a = updateTurnControlPointTurn(u.end, u.start, endNext); } else { Vector3d sp = new Vector3d(u.startPoint); - sp.sub(u.offset); + sp.add(u.offset); a = updateTurnControlPointTurn(u.end, u.endPoint, sp, endNext.getPosition()); } if (a < MIN_TURN_ANGLE && u.end.isDeletable())