| Customize Help
| Save Settings

MimRemap



Function Map
Synopsis
Remap source pixels to destination pixels according to the specified mode.
Syntax
void MimRemap(
MIL_ID RemapContextImId, //in
MIL_ID SrcImageBufId, //in
MIL_ID DstImageBufId, //in
MIL_INT64 ControlFlag //in
)
Description

This function linearly remaps source pixels to destination pixels according to the specified mode, using minimum and maximum buffer values as calculation criteria.

MIL performs remapping calculations using the possible minimum and maximum values of the specified destination image buffer. By default, this is the full value range according to the buffer type. To control these values, use MbufControl() with M_MIN and M_MAX. For the source image buffer, the minimum and maximum values used for calculations depend on the specified remapping mode (ControlFlag).

By default, MIL determines the remapping for the destination image buffer. However, you can specify to remap the values such that the value zero in the source buffer maps to the value zero in the destination buffer with M_CENTERED. Note that saturation can occur when M_CENTERED is specified.

Note that this function reference has not been updated for a MIL system added during a MIL update. Refer to the MIL system's release note to see which MIL system’s documentation you should use in its place and any possible differences.
Parameters
This function is not supported on the selected boards.
This function reference has not been updated for the selected MIL system. To show the content of this page, choose a second MIL system; refer to the MIL system's release note to see which MIL system’s documentation to choose and any possible differences.
Parameters
RemapContextImId

Specifies the identifier of a remap image processing context. This parameter must be set to M_DEFAULT, which indicates a linear remapping from source pixel to corresponding destination pixel.

SrcImageBufId

Specifies the identifier of the source image buffer. The image buffer must be a 1-band or 3-band float, signed, or unsigned buffer.

If the image buffer has a region of interest (ROI) associated with it, the ROI must be in M_RASTER or M_VECTOR_AND_RASTER format. Using an image buffer with an M_VECTOR ROI will cause an error.

DstImageBufId

Specifies the identifier of the destination image buffer.

If the image buffer has a region of interest (ROI) associated with it, the ROI must be in M_RASTER or M_VECTOR_AND_RASTER format. Using an image buffer with an M_VECTOR ROI will cause an error.

ControlFlag

Specifies the remapping mode.

function map For specifying the remapping method to perform
Click to summarizeValue Description
Click to summarize M_DEFAULT

Same as M_FIT_SRC_RANGE.

Click to summarize M_FIT_SRC_DATA +

Specifies to remap according to the source data. The true minimum and maximum pixel values will be calculated from the source image buffer using MimFindExtreme().

(summarize)
Click to summarize M_FIT_SRC_RANGE +

Specifies to remap according to the minimum and maximum pixel values specified for the source image buffer (MbufControl() with M_MIN and M_MAX). By default, this is the full value range according to the buffer type.

(summarize)
Combination value for M_FIT_SRC_DATA; M_FIT_SRC_RANGE.

You can add the following value to the above-mentioned values to specify to keep the range centered to zero.

function map For specifying the remapping centered to zero
Click to summarizeCombination value Description
Click to summarize M_CENTERED

Specifies to center the range to zero.

Compilation information
Header Include mil.h.
Library Use mil.lib; milim.lib.
DLL Requires mil.dll; milim.dll.
PROC VECTOR PROC VECTOR DEFAULT FIT SRC DATA FIT SRC RANGE CENTERED