gen_ellipse_contour_xld ( : ContEllipse : Row, Column, Phi, Radius1, Radius2, StartPhi, EndPhi, PointOrder, Resolution : )

Creation of an XLD contour corresponding to an elliptic arc.

gen_ellipse_contour_xld creates one or more elliptic arcs or closed ellipses. Ellipses are specified by their center (Row, Column), the orientation of the main axis Phi, the length of the larger half axis Radius1, and the length of the smaller half axis Radius2. In addition to that, elliptic arcs are characterized by the angle of the start point StartPhi, the angle of the end point EndPhi, and the point order PointOrder along the boundary. The angles in the interval [0,2*PI] are measured in the coordinate system of the ellipse relative to the main axis. Thus, the two main poles correspond to the angles 0 and PI, the two other poles to the angles PI/2 and 3*pi/2. To create a closed ellipse the values 0 and 2*PI (with positive point order) have to be passed to the operator. The resolution of the resulting contours ContEllipse is controlled via Resolution containing the maximum Euclidean distance between neighboring contour points.


Parameters

ContEllipse (output_object)
xld_cont(-array) -> object
Resulting contour.

Row (input_control)
ellipse.center.y(-array) -> real
Row coordinate of the center of the ellipse.
Default value: 200.0
Suggested values: 0.0, 10.0, 20.0, 50.0, 100.0, 200.0, 300.0, 400.0

Column (input_control)
ellipse.center.x(-array) -> real
Column coordinate of the center of the ellipse.
Default value: 200.0
Suggested values: 0.0, 10.0, 20.0, 50.0, 100.0, 200.0, 300.0, 400.0

Phi (input_control)
ellipse.angle.rad(-array) -> real
Orientation of the main axis [rad].
Default value: 0.0
Suggested values: -1.178097, -0.785398, -0.392699, 0.0, 0.392699, 0.785398, 1.178097
Restriction: (Phi >= 0) && (Phi <= 6.283185307)

Radius1 (input_control)
ellipse.radius1(-array) -> real
Length of the larger half axis.
Default value: 100.0
Suggested values: 2.0, 5.0, 10.0, 20.0, 50.0, 100.0, 256.0, 300.0, 400.0
Restriction: Radius1 > 0

Radius2 (input_control)
ellipse.radius2(-array) -> real
Length of the smaller half axis.
Default value: 50.0
Suggested values: 1.0, 2.0, 4.0, 5.0, 10.0, 20.0, 50.0, 100.0, 256.0, 300.0, 400.0
Restriction: (Radius2 >= 0) && (Radius2 <= Radius1)

StartPhi (input_control)
real(-array) -> real
Angle of the start point [rad].
Default value: 0.0
Suggested values: 0.0, 0.78539, 1.57079, 2.35619, 3.14159, 3.92699, 4.71238, 5.49778, 6.28318
Restriction: (StartPhi >= 0) && (StartPhi <= 6.283185307)

EndPhi (input_control)
real(-array) -> real
Angle of the end point [rad].
Default value: 6.28318
Suggested values: 0.0, 0.78539, 1.57079, 2.35619, 3.14159, 3.92699, 4.71238, 5.49778, 6.28318
Restriction: (EndPhi >= 0) && (EndPhi <= 6.283185307)

PointOrder (input_control)
string(-array) -> string
point order along the boundary.
Default value: 'positive'
List of values: 'positive', 'negative'

Resolution (input_control)
real -> real
Resolution: Maximum distance bewteen neighboring contour points.
Default value: 1.5
Suggested values: 0.5, 1.0, 1.5, 2.0, 2.5, 3.0
Restriction: Resolution > 0


Example
draw_ellipse(WindowHandle,Row,Column,Phi,Radius1,Radius2) 
gen_ellipse_contour_xld(Ellipse,Row,Column,Phi,Radius1,Radius2,0,6.28319,
                        'positive',1.5)
length_xld(Ellipse,Length).

Result

gen_ellipse_contour_xld returns 2 (H_MSG_TRUE) if all parameter values are correct. If necessary, an exception is raised.


Parallelization Information

gen_ellipse_contour_xld is reentrant and processed without parallelization.


Possible Predecessors

draw_ellipse


Possible Successors

disp_xld, get_points_ellipse


Module

Sub-pixel operators



Copyright © 1996-2005 MVTec Software GmbH