eVision Python API
Loading...
Searching...
No Matches
eVision.Legacy.EFrame Class Reference

Represents a geometrical frame of reference as well as the parameters needed to transform from/to local and global coordinates. More...

Inheritance diagram for eVision.Legacy.EFrame:

Public Member Functions

None __init__ (self)
 Constructs a eVision.Legacy.EFrame object.
None __init__ (self, float centerX, float centerY, float angle, float scale)
 Constructs a eVision.Legacy.EFrame object.
None __init__ (self, float centerX, float centerY, float angle)
 Constructs a eVision.Legacy.EFrame object.
None __init__ (self, float centerX, float centerY)
 Constructs a eVision.Legacy.EFrame object.
None __init__ (self, eVision.EPoint center, float angle, float scale)
 Constructs a eVision.Legacy.EFrame object.
None __init__ (self, eVision.Legacy.EFrame frame)
 Constructs a eVision.Legacy.EFrame object.
None CopyTo (self, eVision.Legacy.EFrame other)
 Copies all the data from the current eVision.Legacy.EFrame object into another eVision.Legacy.EFrame object, and returns it.
eVision.EPoint LocalToGlobal (self, eVision.EPoint local)
 Transforms a geometrical element from local to global coordinates (local to world).
eVision.Legacy.ELine LocalToGlobal (self, eVision.Legacy.ELine local)
 Transforms a geometrical element from local to global coordinates (local to world).
eVision.Legacy.ECircle LocalToGlobal (self, eVision.Legacy.ECircle local)
 Transforms a geometrical element from local to global coordinates (local to world).
eVision.Legacy.EFrame LocalToGlobal (self, eVision.Legacy.EFrame local)
 Transforms a geometrical element from local to global coordinates (local to world).
eVision.EPoint GlobalToLocal (self, eVision.EPoint global_)
 Transforms a geometrical element from global to local coordinates (world to local).
eVision.Legacy.EFrame GlobalToLocal (self, eVision.Legacy.EFrame global_)
 Transforms a geometrical element from global to local coordinates (world to local).
None Load (self, str path)
 Load the eVision.Legacy.EFrame configuration.
None Load (self, eVision.ESerializer|None serializer)
 Load the eVision.Legacy.EFrame configuration.
None Save (self, str path)
 Save the eVision.Legacy.EFrame configuration.
None Save (self, eVision.ESerializer|None serializer)
 Save the eVision.Legacy.EFrame configuration.
None SetCenterXY (self, float centerX, float centerY)
 Sets the center coordinates of a eVision.Legacy.EFrame object.
eVision.EPoint MidPoint (self, eVision.EPoint Point)
 Returns the middle coordinate between this eVision.Legacy.EFrame object's center and another eVision.Legacy.EFrame object's center.
eVision.EPoint Rotate (self, float angle)
 Returns another eVision.EPoint object containing the coordinates of the rotated center point.
float Square (self)
 Compute the sum of the squared coordinates of the center of a eVision.Legacy.EFrame.
float Modulus (self)
 Compute the euclidean modulus of the center of a eVision.Legacy.EFrame.
float Argument (self)
 Compute the polar argument of the center of eVision.Legacy.EFrame object.
float Dot (self, eVision.EPoint Point)
 Compute the dot product of the centers of two eVision.Legacy.EFrame objects.
float Cross (self, eVision.EPoint Point)
 Compute the cross product of the centers of two eVision.Legacy.EFrame objects.
float Area (self, eVision.EPoint Point)
 Compute the oriented area of the parallelogram built on the centers of two eVision.Legacy.EFrame.
eVision.EPoint Project (self, eVision.Legacy.ELine shape)
 Compute the orthogonal projection of the center of a eVision.Legacy.EFrame on another shape.
eVision.EPoint Project (self, eVision.Legacy.ECircle shape)
 Compute the orthogonal projection of the center of a eVision.Legacy.EFrame on another shape.
float SquaredDistance (self, eVision.EPoint Point)
 Compute the squared distance between the centers of two eVision.Legacy.EFrame.
eVision.EPoint Move (self, float angle, float distance)
 Return the position by moving the center along angle by distance.
float Distance (self, eVision.EPoint point)
 Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.
float Distance (self, eVision.Legacy.ELine line, bool segmentOnly)
 Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.
float Distance (self, eVision.Legacy.ELine line)
 Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.
float Distance (self, eVision.Legacy.ECircle circle, bool arcOnly)
 Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.
float Distance (self, eVision.Legacy.ECircle circle)
 Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.
float Angle (self)
 Orientation of the frame.
 Angle (self, float value)
 Orientation of the frame.
float Scale (self)
 Horizontal sensor resolution, in pixels per unit.
 Scale (self, float value)
 Horizontal sensor resolution, in pixels per unit.
float CenterX (self)
 Abscissa of the origin point of the frame.
float CenterY (self)
 Ordinate of the origin point of the frame.
eVision.EPoint Center (self)
 Center.
 Center (self, eVision.EPoint value)
 Center.
float X (self)
 Abscissa (X coordinate) of the eVision.Legacy.EFrame object.
 X (self, float value)
 Abscissa (X coordinate) of the eVision.Legacy.EFrame object.
float Y (self)
 Ordinate (Y coordinate) of the eVision.Legacy.EFrame object.
 Y (self, float value)
 Ordinate (Y coordinate) of the eVision.Legacy.EFrame object.

Detailed Description

Represents a geometrical frame of reference as well as the parameters needed to transform from/to local and global coordinates.

It contains a point and an angle and serves as a base class for geometrical elements.

Remarks:

License(s): BasicTypes

Constructor & Destructor Documentation

◆ __init__() [1/6]

None eVision.Legacy.EFrame.__init__ ( self)

Constructs a eVision.Legacy.EFrame object.

◆ __init__() [2/6]

None eVision.Legacy.EFrame.__init__ ( self,
float centerX,
float centerY,
float angle,
float scale )

Constructs a eVision.Legacy.EFrame object.

Parameters
centerXAbscissa of the center point of the frame.
centerYOrdinate of the center point of the frame.
angleOrientation of the frame.
scaleHorizontal sensor resolution.

◆ __init__() [3/6]

None eVision.Legacy.EFrame.__init__ ( self,
float centerX,
float centerY,
float angle )

Constructs a eVision.Legacy.EFrame object.

Parameters
centerXAbscissa of the center point of the frame.
centerYOrdinate of the center point of the frame.
angleOrientation of the frame.

◆ __init__() [4/6]

None eVision.Legacy.EFrame.__init__ ( self,
float centerX,
float centerY )

Constructs a eVision.Legacy.EFrame object.

Parameters
centerXAbscissa of the center point of the frame.
centerYOrdinate of the center point of the frame.

◆ __init__() [5/6]

None eVision.Legacy.EFrame.__init__ ( self,
eVision.EPoint center,
float angle,
float scale )

Constructs a eVision.Legacy.EFrame object.

Parameters
centerCoordinates of the center point of the frame.
angleOrientation of the frame.
scaleHorizontal sensor resolution.

◆ __init__() [6/6]

None eVision.Legacy.EFrame.__init__ ( self,
eVision.Legacy.EFrame frame )

Constructs a eVision.Legacy.EFrame object.

Parameters
framePre-existing eVision.Legacy.EFrame object used by the copy constructor.

Member Function Documentation

◆ Angle() [1/2]

float eVision.Legacy.EFrame.Angle ( self)

Orientation of the frame.

◆ Angle() [2/2]

eVision.Legacy.EFrame.Angle ( self,
float value )

Orientation of the frame.

◆ Area()

float eVision.Legacy.EFrame.Area ( self,
eVision.EPoint Point )

Compute the oriented area of the parallelogram built on the centers of two eVision.Legacy.EFrame.

Remarks:

Compute the oriented area of the parallelogram built on the center of two eVision.Legacy.EFrame. The area is counted as positive if the oriented vector pair ('first edge', 'second edge') is in the same sense that the axis frame. This oriented area can also be viewed as the z-coordinate of a vector product of two 3D vectors obtained in supplementing each edges with a third z-coordinate (set to zero).

Parameters
PointSecond edge of the parallelogram.

Reimplemented in eVision.Legacy.EPolygon.

◆ Argument()

float eVision.Legacy.EFrame.Argument ( self)

Compute the polar argument of the center of eVision.Legacy.EFrame object.

Remarks:

Compute the angle (in radians) between the oriented X-axis and the vector going from the axis origin and the eVision.Legacy.EFrame. If the axis frame is orthogonal, this number is also the polar argument of the eVision.Legacy.EFrame.

◆ Center() [1/2]

eVision.EPoint eVision.Legacy.EFrame.Center ( self)

Center.

◆ Center() [2/2]

eVision.Legacy.EFrame.Center ( self,
eVision.EPoint value )

Center.

◆ CenterX()

float eVision.Legacy.EFrame.CenterX ( self)

Abscissa of the origin point of the frame.

◆ CenterY()

float eVision.Legacy.EFrame.CenterY ( self)

Ordinate of the origin point of the frame.

◆ CopyTo()

None eVision.Legacy.EFrame.CopyTo ( self,
eVision.Legacy.EFrame other )

Copies all the data from the current eVision.Legacy.EFrame object into another eVision.Legacy.EFrame object, and returns it.

Remarks:

In the overload taking a pointer, in case of a NULL pointer, a new eVision.Legacy.EFrame object will be created and returned.

Parameters
otherPointer to the eVision.Legacy.EFrame object in which the current eVision.Legacy.EFrame object data have to be copied.

Reimplemented in eVision.Legacy.ECircle, eVision.Legacy.ELine, eVision.Legacy.EPolygon, eVision.Legacy.ERectangle, and eVision.Legacy.EWedge.

◆ Cross()

float eVision.Legacy.EFrame.Cross ( self,
eVision.EPoint Point )

Compute the cross product of the centers of two eVision.Legacy.EFrame objects.

Parameters
PointSecond factor of the cross product.

◆ Distance() [1/5]

float eVision.Legacy.EFrame.Distance ( self,
eVision.EPoint point )

Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.

Remarks:

Many EasyGauge members provide measurement result as a eVision.EPoint object (see eVision.Legacy.EPointGauge.Center, eVision.Legacy.EPointGauge.GetMeasuredPoint,...). The eVision.Legacy.EFrame class has its own members to retrieve all the information pertaining to a point. Among them, the Distance method returns the distance between a point pair or between a point and a line segment, a circle arc or a rectangle.

Parameters
pointeVision.EPoint object with which to calculate the distance.

Reimplemented in eVision.Legacy.ECircle.

◆ Distance() [2/5]

float eVision.Legacy.EFrame.Distance ( self,
eVision.Legacy.ECircle circle )

Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.

Remarks:

Many EasyGauge members provide measurement result as a eVision.EPoint object (see eVision.Legacy.EPointGauge.Center, eVision.Legacy.EPointGauge.GetMeasuredPoint,...). The eVision.Legacy.EFrame class has its own members to retrieve all the information pertaining to a point. Among them, the Distance method returns the distance between a point pair or between a point and a line segment, a circle arc or a rectangle.

Parameters
circleeVision.Legacy.ECircle object with which to calculate the distance.

Reimplemented in eVision.Legacy.ECircle.

◆ Distance() [3/5]

float eVision.Legacy.EFrame.Distance ( self,
eVision.Legacy.ECircle circle,
bool arcOnly )

Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.

Remarks:

Many EasyGauge members provide measurement result as a eVision.EPoint object (see eVision.Legacy.EPointGauge.Center, eVision.Legacy.EPointGauge.GetMeasuredPoint,...). The eVision.Legacy.EFrame class has its own members to retrieve all the information pertaining to a point. Among them, the Distance method returns the distance between a point pair or between a point and a line segment, a circle arc or a rectangle.

Parameters
circleeVision.Legacy.ECircle object with which to calculate the distance.
arcOnlyBy default (false), the circle is not restricted to an arc.

Reimplemented in eVision.Legacy.ECircle.

◆ Distance() [4/5]

float eVision.Legacy.EFrame.Distance ( self,
eVision.Legacy.ELine line )

Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.

Remarks:

Many EasyGauge members provide measurement result as a eVision.EPoint object (see eVision.Legacy.EPointGauge.Center, eVision.Legacy.EPointGauge.GetMeasuredPoint,...). The eVision.Legacy.EFrame class has its own members to retrieve all the information pertaining to a point. Among them, the Distance method returns the distance between a point pair or between a point and a line segment, a circle arc or a rectangle.

Parameters
lineeVision.Legacy.ELine object with which to calculate the distance.

Reimplemented in eVision.Legacy.ECircle.

◆ Distance() [5/5]

float eVision.Legacy.EFrame.Distance ( self,
eVision.Legacy.ELine line,
bool segmentOnly )

Returns the distance between the addressed point and the center of eVision.Legacy.EFrame object.

Remarks:

Many EasyGauge members provide measurement result as a eVision.EPoint object (see eVision.Legacy.EPointGauge.Center, eVision.Legacy.EPointGauge.GetMeasuredPoint,...). The eVision.Legacy.EFrame class has its own members to retrieve all the information pertaining to a point. Among them, the Distance method returns the distance between a point pair or between a point and a line segment, a circle arc or a rectangle.

Parameters
lineeVision.Legacy.ELine object with which to calculate the distance.
segmentOnlyBy default (false), the line is not restricted to a segment.

Reimplemented in eVision.Legacy.ECircle.

◆ Dot()

float eVision.Legacy.EFrame.Dot ( self,
eVision.EPoint Point )

Compute the dot product of the centers of two eVision.Legacy.EFrame objects.

Parameters
PointSecond factor of the dot product.

◆ GlobalToLocal() [1/2]

eVision.EPoint eVision.Legacy.EFrame.GlobalToLocal ( self,
eVision.EPoint global_ )

Transforms a geometrical element from global to local coordinates (world to local).

Parameters
global_The element, expressed in global coordinates.

◆ GlobalToLocal() [2/2]

eVision.Legacy.EFrame eVision.Legacy.EFrame.GlobalToLocal ( self,
eVision.Legacy.EFrame global_ )

Transforms a geometrical element from global to local coordinates (world to local).

Parameters
global_The element, expressed in global coordinates.

◆ Load() [1/2]

None eVision.Legacy.EFrame.Load ( self,
eVision.ESerializer | None serializer )

Load the eVision.Legacy.EFrame configuration.

The given eVision.ESerializer must have been created for reading.

Parameters
serializerThe serializer.

Reimplemented in eVision.Legacy.ELine, eVision.Legacy.ELine, eVision.Legacy.EPolygon, and eVision.Legacy.EPolygon.

◆ Load() [2/2]

None eVision.Legacy.EFrame.Load ( self,
str path )

Load the eVision.Legacy.EFrame configuration.

The given eVision.ESerializer must have been created for reading.

Parameters
pathThe file path.

Reimplemented in eVision.Legacy.ELine, eVision.Legacy.ELine, eVision.Legacy.EPolygon, and eVision.Legacy.EPolygon.

◆ LocalToGlobal() [1/4]

eVision.EPoint eVision.Legacy.EFrame.LocalToGlobal ( self,
eVision.EPoint local )

Transforms a geometrical element from local to global coordinates (local to world).

Parameters
localThe element, expressed in local coordinates.

◆ LocalToGlobal() [2/4]

eVision.Legacy.ECircle eVision.Legacy.EFrame.LocalToGlobal ( self,
eVision.Legacy.ECircle local )

Transforms a geometrical element from local to global coordinates (local to world).

Parameters
localThe element, expressed in local coordinates.

◆ LocalToGlobal() [3/4]

eVision.Legacy.EFrame eVision.Legacy.EFrame.LocalToGlobal ( self,
eVision.Legacy.EFrame local )

Transforms a geometrical element from local to global coordinates (local to world).

Parameters
localThe element, expressed in local coordinates.

◆ LocalToGlobal() [4/4]

eVision.Legacy.ELine eVision.Legacy.EFrame.LocalToGlobal ( self,
eVision.Legacy.ELine local )

Transforms a geometrical element from local to global coordinates (local to world).

Parameters
localThe element, expressed in local coordinates.

◆ MidPoint()

eVision.EPoint eVision.Legacy.EFrame.MidPoint ( self,
eVision.EPoint Point )

Returns the middle coordinate between this eVision.Legacy.EFrame object's center and another eVision.Legacy.EFrame object's center.

Parameters
PointThe other point.

◆ Modulus()

float eVision.Legacy.EFrame.Modulus ( self)

Compute the euclidean modulus of the center of a eVision.Legacy.EFrame.

Remarks:

Compute the squared root of the sum of the squared coordinates of an eVision.Legacy.EFrame. If the axis frame is orthogonal, this number is also the euclidean norm of the eVision.Legacy.EFrame.

◆ Move()

eVision.EPoint eVision.Legacy.EFrame.Move ( self,
float angle,
float distance )

Return the position by moving the center along angle by distance.

Parameters
angleThe direction of the displacement, in radians.
distanceThe distance of the displacement.

◆ Project() [1/2]

eVision.EPoint eVision.Legacy.EFrame.Project ( self,
eVision.Legacy.ECircle shape )

Compute the orthogonal projection of the center of a eVision.Legacy.EFrame on another shape.

Remarks:

Compute the orthogonal projection of a eVision.Legacy.EFrame on another shape. This computation is only valid when the axis frame is orthogonal.

Parameters
shapeShape object to which point is projected

◆ Project() [2/2]

eVision.EPoint eVision.Legacy.EFrame.Project ( self,
eVision.Legacy.ELine shape )

Compute the orthogonal projection of the center of a eVision.Legacy.EFrame on another shape.

Remarks:

Compute the orthogonal projection of a eVision.Legacy.EFrame on another shape. This computation is only valid when the axis frame is orthogonal.

Parameters
shapeShape object to which point is projected

◆ Rotate()

eVision.EPoint eVision.Legacy.EFrame.Rotate ( self,
float angle )

Returns another eVision.EPoint object containing the coordinates of the rotated center point.

Remarks:

Rotates a eVision.Legacy.EFrame around the origin (0, 0) by an angle of angle radians. By definition, the smallest (in absolute value) rotation of the oriented X-Axis toward the oriented Y-Axis is chosen as the positive sense of rotation. In a direct frame, this is also the trigonometric sense (counter clockwise).

Parameters
angleRotation angle (in radians)

◆ Save() [1/2]

None eVision.Legacy.EFrame.Save ( self,
eVision.ESerializer | None serializer )

Save the eVision.Legacy.EFrame configuration.

The given eVision.ESerializer must have been created for writing.

Parameters
serializerThe serializer.

Reimplemented in eVision.Legacy.ELine, eVision.Legacy.ELine, eVision.Legacy.EPolygon, and eVision.Legacy.EPolygon.

◆ Save() [2/2]

None eVision.Legacy.EFrame.Save ( self,
str path )

Save the eVision.Legacy.EFrame configuration.

The given eVision.ESerializer must have been created for writing.

Parameters
pathThe file path.

Reimplemented in eVision.Legacy.ELine, eVision.Legacy.ELine, eVision.Legacy.EPolygon, and eVision.Legacy.EPolygon.

◆ Scale() [1/2]

float eVision.Legacy.EFrame.Scale ( self)

Horizontal sensor resolution, in pixels per unit.

◆ Scale() [2/2]

eVision.Legacy.EFrame.Scale ( self,
float value )

Horizontal sensor resolution, in pixels per unit.

◆ SetCenterXY()

None eVision.Legacy.EFrame.SetCenterXY ( self,
float centerX,
float centerY )

Sets the center coordinates of a eVision.Legacy.EFrame object.

Parameters
centerXCenter coordinates of the origin.
centerYCenter coordinates of the origin.

◆ Square()

float eVision.Legacy.EFrame.Square ( self)

Compute the sum of the squared coordinates of the center of a eVision.Legacy.EFrame.

Remarks:

Compute the sum of the squared coordinates of a eVision.Legacy.EFrame. If the axis frame is orthogonal, this sum of squares is also the squared euclidean norm of the eVision.Legacy.EFrame object.

◆ SquaredDistance()

float eVision.Legacy.EFrame.SquaredDistance ( self,
eVision.EPoint Point )

Compute the squared distance between the centers of two eVision.Legacy.EFrame.

Remarks:

Compute the sum of squared coordinates differences of two eVision.Legacy.EFrame. If the axis frame is orthogonal, this number is also the squared euclidean distance between two eVision.Legacy.EFrame.

Parameters
PointSecond eVision.Legacy.EFrame.

◆ X() [1/2]

float eVision.Legacy.EFrame.X ( self)

Abscissa (X coordinate) of the eVision.Legacy.EFrame object.

◆ X() [2/2]

eVision.Legacy.EFrame.X ( self,
float value )

Abscissa (X coordinate) of the eVision.Legacy.EFrame object.

◆ Y() [1/2]

float eVision.Legacy.EFrame.Y ( self)

Ordinate (Y coordinate) of the eVision.Legacy.EFrame object.

◆ Y() [2/2]

eVision.Legacy.EFrame.Y ( self,
float value )

Ordinate (Y coordinate) of the eVision.Legacy.EFrame object.