Skip to content

Commit

Permalink
0001279: Wrong operator in DraftGeomUtils.getRotation
Browse files Browse the repository at this point in the history
  • Loading branch information
yorikvanhavre committed Oct 18, 2013
1 parent e18fb98 commit 5233aa7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Mod/Draft/DraftGeomUtils.py
Expand Up @@ -909,7 +909,8 @@ def getRotation(v1,v2=FreeCAD.Vector(0,0,1)):
return None
axis = v1.cross(v2)
axis.normalize()
angle = math.degrees(math.sqrt((v1.Length ^ 2) * (v2.Length ^ 2)) + v1.dot(v2))
#angle = math.degrees(math.sqrt((v1.Length ^ 2) * (v2.Length ^ 2)) + v1.dot(v2))
angle = math.degrees(DraftVecUtils.angle(v1,v2,axis))
return FreeCAD.Rotation(axis,angle)

def calculatePlacement(shape):
Expand Down

0 comments on commit 5233aa7

Please sign in to comment.