Fixed bug with bisector.
--HG-- branch : develop
This commit is contained in:
parent
7b56218e09
commit
ca61b27599
|
@ -42,8 +42,10 @@ QPointF VToolBisector::FindPoint(const QPointF &firstPoint, const QPointF &secon
|
||||||
qreal angle = line1.angleTo(line2);
|
qreal angle = line1.angleTo(line2);
|
||||||
if(angle>180){
|
if(angle>180){
|
||||||
angle = 360 - angle;
|
angle = 360 - angle;
|
||||||
}
|
|
||||||
line1.setAngle(line1.angle()-angle/2);
|
line1.setAngle(line1.angle()-angle/2);
|
||||||
|
} else {
|
||||||
|
line1.setAngle(line1.angle()+angle/2);
|
||||||
|
}
|
||||||
line1.setLength(length);
|
line1.setLength(length);
|
||||||
return line1.p2();
|
return line1.p2();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user