imaqGetPointsOnContour
Usage
SegmentInfo* imaqGetPointsOnContour(const Image* image, int* numSegments);
Purpose
Finds the number of edge segments in an image and returns the coordinates of the pixels in each segment. Any pixel that is greater than zero is considered an edge location.
This function groups adjoining edge pixels into edge segments. An edge segment is considered closed if it forms a loop. Each edge segment is given a weight based on the pixel gray values along that edge. An edge segment with high gray values has a higher weight.
Image Types Supported
IMAQ_IMAGE_U8
Parameters
Name
|
Type
|
Description
|
---|---|---|
image | const Image* | The image in which to find the segments. |
numSegments | int* | On return, the number of segments found. Set this parameter to NULL if you do not need this information. |
Return Value
Type |
Description |
---|---|
SegmentInfo* | On success, this function returns an array of information about the segments. On failure, this function returns NULL. To get extended error information, call imaqGetLastError().When you are finished with the information, dispose of it by calling imaqDispose(). |