MIL_ID SrcImageBufId, | //in |
MIL_ID DstImageBufId, | //in |
MIL_DOUBLE ScaleFactorX, | //in |
MIL_DOUBLE ScaleFactorY, | //in |
MIL_INT64 InterpolationMode | //in |
This function resizes the source image by the specified factors. Results are stored in the destination buffer starting from the top-left corner.
Specifies the identifier of the data source of the operation. This parameter must be given an image buffer identifier.
This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.
The source image buffer must be unsigned monochrome 8- or 16-bit, or M_BGR32 packed.
Specifies the identifier of the destination of the results. This parameter must be given an image buffer identifier.
This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.
Note that after performing the operation, the destination image will not be calibrated, even if the source image was calibrated.
The destination image buffer must be unsigned monochrome 8- or 16-bit, or M_BGR32 packed.
Specifies the scaling factor for the width of the source image. This parameter can be set to one of the values below.
For specifying the scaling factor
(width)
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
||||||||||||||||||||||||||||||||||||||
M_FILL_DESTINATION |
Resizes the source image to fill the entire width of the destination buffer. (more details...) |
||||||||||||||||||||||||||||||||||||||
Value > 0.0 |
Uses a non-null positive value to multiply the width of the source image. (more details...) |
Specifies the scaling factor for the height of the source image. This parameter can be set to one of the values below.
For specifying the scaling factor
(height)
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
||||||||||||||||||||||||||||||||||||||
M_FILL_DESTINATION |
Resizes the source image to fill the entire height of the destination buffer. (more details...) |
||||||||||||||||||||||||||||||||||||||
Value > 0.0 |
Uses a non-null positive value to multiply the height of the source image. (more details...) |
Specifies the mode of interpolation. This parameter can be set to one of the values below.
For specifying the mode of
interpolation
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
MIL system-specific tooltip (†) |
|||||||||||||||||||||||||||||||||||||
M_DEFAULT |
Same as M_NEAREST_NEIGHBOR + M_OVERSCAN_ENABLE + M_FAST. |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
M_AVERAGE + |
Specifies averaging interpolation. (more details...) |
† | a | b | c | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | |||||||||||||||||||
M_BICUBIC + |
Specifies bicubic interpolation. (more details...) |
† | a | b | c | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | |||||||||||||||||||
M_BILINEAR + |
Specifies bilinear interpolation. (more details...) |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
M_INTERPOLATE + |
Specifies interpolated resizing: for zooming = bilinear, for dezooming = averaging. (more details...) |
† | a | b | c | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | |||||||||||||||||||
M_MAX + |
Specifies an interpolation based on the maximum pixel value in the specified source image. (more details...) |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
M_MIN + |
Specifies an interpolation based on the minimum pixel value in the specified source image. (more details...) |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
M_NEAREST_NEIGHBOR + |
Specifies the nearest neighbor interpolation. (more details...) |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s |
You can add one of the following values to the above-mentioned values to specify how to determine the value of a destination pixel when its associated point falls outside the source buffer.
For overscan
|
|||||||||||||||||||||||||||||||||||||||
Combination value |
Description
|
MIL system-specific tooltip (†) |
|||||||||||||||||||||||||||||||||||||
M_OVERSCAN_CLEAR |
Sets the destination pixel to 0. |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
M_OVERSCAN_DISABLE |
Leaves the destination pixel as is. |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
M_OVERSCAN_ENABLE |
Uses pixels from the source buffer's ancestor buffer. (more details...) |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | ||||||||||||||||||
MIL system specific | |||||||||||||||||||||||||||||||||||||||
Points falling outside the source image are undefined. |
† | d | j | k | l | m | p | q | r | ||||||||||||||||||||||||||||||
M_OVERSCAN_FAST |
Specifies that MIL will automatically select the overscan that optimizes speed, according to the specified operation and the target system. (more details...) |
† | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s |
You can add one of the following values to the above-mentioned values to specify the speed and precision of the interpolation.
For the speed and precision
|
|||||||||||||||||||||||||||||||||||||||
Combination value | Description
|
||||||||||||||||||||||||||||||||||||||
M_FAST |
Uses a fast interpolation. (more details...) |
||||||||||||||||||||||||||||||||||||||
M_REGULAR |
Uses a slow interpolation. (more details...) |
Header | Include mil.h. |
Library | Use mil.lib; milim.lib. |
DLL | Requires mil.dll; milim.dll. |