maskIm
|
|
Input
|
|
An integer between 0 and 116 specifying the input image frame number. A value of 0 represents the DMA memory buffer of the video device. Values in the range of 100-116 correspond to hidden frames.
|
|
Mask
|
|
An integer between 0 and 116 specifying the frame number of the multiphase image used as a mask. A value of 0 represents the DMA memory buffer of the video device. Values in the range of 100-116 correspond to hidden frames.
|
|
Output
|
|
An integer between 1 and 116 specifying the output image frame number. Values in the range of 100-116 correspond to hidden frames.
|
|
Phase
|
|
An optional integer between 0 and 255 specifying the phase that will be used for masking. Only those pixels in the input image that have the corresponding pixels in the Mask image equal to the value of Phase will be extracted.
|
Default value: 1
|
|
Invert
|
|
An optional boolean integer that defines if the operation should be inverted. Must be one of the following values:
|
FALSE=0 the operation is performed as described above.
|
TRUE=1- inverts the operation and extracts those area of the input image that are not masked.
|
Default value: FALSE
|
|
ERR_OK
|
|
The flag set if successful.
|
|
ERR_FAILED
|
|
The flag set if failed.
|
This set of statements continuously grabs an image and masks it with a hidden binary image that contains an ellipse and rectangle:
|
|
createIm (100,IM_MULTI,512,512)
|
phase=1
|
drawEllipse (100,50,50,350,300,TRUE,phase)
|
drawRect(100,350,350,480,450,TRUE,phase)
|
do
|
grabIm(101)
|
maskIm (101,100,1,phase)
|
loop
|
|