MIL_ID DstContainerOrBufId, | //in |
MIL_DOUBLE Color | //in |
This function clears the specified buffer, or the components of the specified container, to the specified color.
To clear a 16-bit or 32-bit multi-band image buffer to a color value, use MgraClear().
For an image buffer, the clear can be limited to a region of interest (ROI) set using MbufSetRegion().
Using this function with a container is equivalent to using it individually with each component of the container. An error will be generated if the container has a component that cannot be cleared (for example, because it has an ROI defined only in a vector format).
Using this function with a buffer always results in an uncalibrated image. Any previously associated camera calibration context is removed. You can use MgraClear() to clear a buffer while preserving the camera calibration context associated with the empty image.
Specifies the identifier of the buffer or container to clear. If you specify an image buffer, it can have an ROI set using MbufSetRegion(). The ROI must be defined in raster format (M_RASTER or M_VECTOR_AND_RASTER). An error is generated if the ROI is only in vector format (M_VECTOR).
Specifies the color value with which to clear the buffer.
For a 3-band image buffer, this parameter can be set to one of the following color values:
For specifying a color value
|
|||||||||||||||||||||||||||||||||||||||
Value | Description | ||||||||||||||||||||||||||||||||||||||
Specifies an RGB value used to clear an 8-bit 3-band buffer to an RGB color. Each value (red, green or blue) must not exceed 8 bits. (summarize)Specifies an RGB value used to clear an 8-bit 3-band buffer to an RGB color. (more details...) |
|||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Specifies the red component, as a value between 0 and 255. |
|||||||||||||||||||||||||||||||||||||||
Specifies the green component, as a value between 0 and 255. |
|||||||||||||||||||||||||||||||||||||||
Specifies the blue component, as a value between 0 and 255. |
|||||||||||||||||||||||||||||||||||||||
M_COLOR_BLACK |
Specifies the color black. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_BLUE |
Specifies the color blue. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_BRIGHT_GRAY |
Specifies the color bright gray. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_CYAN |
Specifies the color cyan. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_DARK_BLUE |
Specifies the color dark blue. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_DARK_CYAN |
Specifies the color dark cyan. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_DARK_GREEN |
Specifies the color dark green. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_DARK_MAGENTA |
Specifies the color dark magenta. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_DARK_RED |
Specifies the color dark red. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_DARK_YELLOW |
Specifies the color dark yellow. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_GRAY |
Specifies the color gray. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_GREEN |
Specifies the color green. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_LIGHT_BLUE |
Specifies the color light blue. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_LIGHT_GRAY |
Specifies the color light gray. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_LIGHT_GREEN |
Specifies the color light green. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_LIGHT_WHITE |
Specifies the color light white. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_MAGENTA |
Specifies the color magenta. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_RED |
Specifies the color red. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_WHITE |
Specifies the color white. |
||||||||||||||||||||||||||||||||||||||
M_COLOR_YELLOW |
Specifies the color yellow. |
For a 1-band or 3-band buffer, you can set this parameter to the following grayscale value:
For specifying a grayscale value to be used with all
bands
|
|||||||||||||||||||||||||||||||||||||||
Value | Description | ||||||||||||||||||||||||||||||||||||||
Value |
Specifies a grayscale value used to clear the 1-band or multi-band buffer. This value is cast to the buffer type and depth. If the destination buffer is 3-band, this value will be replicated in each band. (summarize)Specifies a grayscale value used to clear the 1-band or multi-band buffer. (more details...) |
Header | Include mil.h. |
Library | Use mil.lib. |
DLL | Requires mil.dll. |