mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2025-01-01 04:10:34 +05:00
Update for bug 0019891 from Mantis.
This commit is contained in:
parent
01421722a7
commit
54dcca730e
@ -152,6 +152,13 @@ def TestMeasureOperations (geompy, math):
|
||||
if math.fabs(Angle - 45.0) > 1e-05:
|
||||
print " Error: returned angle is", Angle, "while must be 45.0"
|
||||
|
||||
Angle = geompy.GetAngleRadians(OX, OXY)
|
||||
|
||||
print "\nAngle between OX and OXY in radians = ", Angle
|
||||
if math.fabs(Angle - math.pi/4) > 1e-05:
|
||||
print " Error: returned angle is", Angle, "while must be pi/4"
|
||||
pass
|
||||
|
||||
# not in one plane
|
||||
OXY_shift = geompy.MakeTranslation(OXY,10,-10,20)
|
||||
Angle = geompy.GetAngle(OX, OXY_shift)
|
||||
|
@ -2432,7 +2432,7 @@ class geompyDC(GEOM._objref_GEOM_Gen):
|
||||
def GetAngleRadians(self, theShape1, theShape2):
|
||||
# Example: see GEOM_TestMeasures.py
|
||||
anAngle = self.MeasuOp.GetAngle(theShape1, theShape2)*math.pi/180.
|
||||
RaiseIfFailed("GetAngleRadians", self.MeasuOp)
|
||||
RaiseIfFailed("GetAngle", self.MeasuOp)
|
||||
return anAngle
|
||||
|
||||
## @name Curve Curvature Measurement
|
||||
|
Loading…
Reference in New Issue
Block a user