imaqOverlayClosedContour

NI Vision for LabWindows/CVI Function

imaqOverlayClosedContour

Usage

int imaqOverlayClosedContour(Image* image, const Point* points, int numPoints, const RGBValue* color, DrawMode drawMode, const char* group);

Purpose

Overlays an closed contour onto an image. To make the contour, the function connects each point in the array to the next point in the array, and it connects the last point in the array to the first point in the array.

Image Types Supported

IMAQ_IMAGE_U8, IMAQ_IMAGE_U16, IMAQ_IMAGE_I16, IMAQ_IMAGE_SGL, IMAQ_IMAGE_COMPLEX, IMAQ_IMAGE_RGB, IMAQ_IMAGE_HSL, IMAQ_IMAGE_RGB_U64

Parameters

Name

Type

Description

image Image* The image on which to overlay the open contour.
points const Point* An array of points describing the location and shape of the contour. This parameter is required and cannot be NULL.
numPoints int The number of points in the array.
color const RGBValue* The color of the contour. The alpha color channel is not supported. Setting the color to transparent has the same effect as selecting black. This parameter is required and cannot be NULL.
drawMode DrawMode The mode by which to draw the overlay. IMAQ_DRAW_VALUE and IMAQ_PAINT_VALUE are valid options.
group const char* The group to which you want to add the overlay. Set this parameter to NULL to add the overlay to the default group.

Return Value

Type

Description

int On success, this function returns a non-zero value. On failure, this function returns 0. To get extended error information, call imaqGetLastError().