Create a rectangle of any orientation.
The operator rectangle2 generates one or more rectangles with the center (Row, Column) , the orientation Phi and the half edge lengths Length1 and Length2. The orientation is given in arc measure and indicates the angle between the horizontal axis and Length1 (mathematically positive). The coordinate system runs from (0,0) (upper left corner) to (Width-1,Height-1). See in this connection get_system and init_horus. More than one region can be created by passing one tuple of corner points.
The gray values of the output objects are undefined.
Rectangle (output_object) |
region(-array) -> object |
Created rectangle. |
Row (input_control) |
rectangle2.center.y(-array) -> real / integer |
Line index of the center. | |
Default value: 50.0 | |
Suggested values: 10.0, 20.0, 50.0, 100.0, 200.0, 300.0, 400.0, 500.0 | |
Range of values: 0.0 <= Row <= 511.0 (lin) | |
Minimum increment: 1.0 | |
Recommended increment: 10.0 |
Column (input_control) |
rectangle2.center.x(-array) -> real / integer |
Column index of the center. | |
Default value: 100.0 | |
Suggested values: 10.0, 20.0, 50.0, 100.0, 200.0, 300.0, 400.0, 500.0 | |
Range of values: 0.0 <= Column <= 511.0 (lin) | |
Minimum increment: 1.0 | |
Recommended increment: 10.0 |
Phi (input_control) |
rectangle2.angle.rad(-array) -> real / integer |
Angle of longitudinal axis to horizontal (arc measure). | |
Default value: 0.0 | |
Suggested values: -1.178097, -0.785398, -0.392699, 0.0, 0.392699, 0.785398, 1.178097 | |
Range of values: -1.178097 <= Phi <= 1.178097 (lin) | |
Minimum increment: 0.001 | |
Recommended increment: 0.1 | |
Restriction: ((- pi / 2) < Phi) && (Phi <= (pi / 2)) |
Length1 (input_control) |
rectangle2.hwidth(-array) -> real / integer |
Half width. | |
Default value: 200.0 | |
Suggested values: 3.0, 5.0, 10.0, 15.0, 20.0, 50.0, 100.0, 200.0, 300.0, 500.0 | |
Range of values: 0.0 <= Length1 <= 511.0 (lin) | |
Minimum increment: 1.0 | |
Recommended increment: 10.0 |
Length2 (input_control) |
rectangle2.hheight(-array) -> real / integer |
Half height. | |
Default value: 100.0 | |
Suggested values: 1.0, 2.0, 3.0, 5.0, 10.0, 15.0, 20.0, 50.0, 100.0, 200.0 | |
Range of values: 0.0 <= Length2 <= 511.0 (lin) | |
Minimum increment: 1.0 | |
Recommended increment: 10.0 | |
Restriction: Length2 <= Length1 |
If the parameter values are correct the operator rectangle2 returns the value TRUE. Otherwise an exception is raised. The clipping of the current image format is set via the operator set_system(::'clip_region',<true/false>:).
rectangle1, store_filled_polygon, store_polygon, store_lines, fill_up
draw_rectangle2, reduce_domain, smallest_rectangle2, ellipse