Access the contour of an object.
The operator fetch_contour returns the contour of a region. A contour is a result of line (Rows) and column coordinates (Columns), describing the boundary of the region. The contour lies on the region. It starts at the smallest line number; in that line at the pixel with the largest column index. The rotation direction is clockwise. The first pixel of the contour is identical with the last. Holes of the region are ignored. The operator fetch_contour returns the coordinates in the form of tuples. An empty region is passed as empty tuple.
Holes of the region are ignored. Only one region may be passed, and this region must have exactly one connection component.
Region (input_object) |
region -> object |
Output region. |
Rows (output_control) |
contour.y-array -> integer |
Line numbers of the contour pixels. |
Columns (output_control) |
contour.x-array -> integer |
Column numbers of the contour pixels. | |
Number of elements: Columns == Rows |
The operator fetch_contour normally returns the value TRUE. If more than one connection component is passed an exception is caused. The behavior in case of empty input (no input regions available) is set via the operator set_system(::'no_object_result',<Result>:).
sobel_amp, threshold__, skeleton, edges__, rectangle1, circle
copy_obj, fetch_chain, fetch_polygon