Click here to show toolbars of the Web Online Help System: show toolbars |
Table: | For specifying the ending angle |
Table: | For selecting the Operation Mode |
+ combination: | For generating LUTs |
MIL_ID SrcImageOrDstXLutBufId, | //in |
MIL_ID DstImageOrYLutBufId, | //in |
MIL_DOUBLE CenterPosX, | //in |
MIL_DOUBLE CenterPosY, | //in |
MIL_DOUBLE StartRadius, | //in |
MIL_DOUBLE EndRadius, | //in |
MIL_DOUBLE StartAngle, | //in |
MIL_DOUBLE EndAngle, | //in |
MIL_INT64 OperationMode, | //in |
MIL_INT64 InterpolationMode, | //in |
MIL_DOUBLE *DstSizeXPtr, | //out |
MIL_DOUBLE *DstSizeYPtr | //out |
This function performs a rectangular-to-polar or polar-to-rectangular transformation. Alternatively, this function can generate the X- and Y-coordinate LUTs required to perform the transformation using MimWarp().
For a rectangular-to-polar transformation, the zone of interest to convert is based on a circle centered at CenterPosX and CenterPosY, with the part to convert having the specified start and end radius (StartRadius and EndRadius) and specified start and end angle (StartAngle and EndAngle), measured with respect to the X-axis of the image.
The result will be mapped to the destination buffer as follows:
The increment in angle is determined by the length, in pixels, of the outside arc, calculated as follows:
(endangle - startangle) / arclength.
A polar-to-rectangular transform performs the reverse of the transform described above. It takes a polar buffer and maps it to a rectangular buffer. Use the CenterPosX, CenterPosY, StartAngle, EndAngle, StartRadius, EndRadius parameters to specify where in the destination buffer the contents of the polar buffer will be mapped.
To determine the required size of the destination image or LUT buffer, call the function with DstImageOrYLutBufId set to M_NULL; in this case, DstSizeXPtr and DstSizeYPtr will return the required X- and Y- size of the buffer, respectively. Note that DstSizeXPtr and DstSizeYPtr will return MIL_DOUBLE values; to allocate an appropriate buffer using these values, you should use a ceiling function, such as ceil(), to obtain the X- and Y- sizes as integer (MIL_INT) values.
Specifies the identifier of the source image buffer or the destination X-coordinate LUT buffer.
See the Parameter associations section for possible values that can be specified.
Specifies the identifier of the destination image buffer or the Y-coordinate LUT buffer.
See the Parameter associations section for possible values that can be specified.
Specifies the start angle of the zone of interest. The scan starts at this angle.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the start angle. |
Specifies the end angle of the zone of interest. The scan ends at this angle.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the end angle. |
Specifies the transform to perform.
See the Parameter associations section for possible values that can be specified.
Specifies the interpolation mode and overscan used when transforming the source image. When generating the LUTs to perform the transformation, this parameter is ignored and should be set to M_DEFAULT.
This parameter must be set to one of the values below.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description |
MIL system-specific tooltip (‡) |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
||||||||||||||||
![]() ![]() |
Specifies the default interpolation mode and overscan. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Performs bicubic interpolation. |
‡ | a | b | c | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | |||||||||||||||||
![]() ![]() |
Performs bilinear interpolation. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Performs nearest-neighbor interpolation. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u |
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.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description |
MIL system-specific tooltip (‡) |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
||||||||||||||||
![]() ![]() |
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 | t | u | ||||||||||||||||
![]() ![]() |
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 | t | u | ||||||||||||||||
![]() ![]() |
Uses pixels from the source buffer's ancestor buffer. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
MIL system specific | |||||||||||||||||||||||||||||||||||||||
Points falling outside the source image are undefined. |
‡ | d | j | k | l | m | p | q | r | ||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that MIL will automatically select the overscan that optimizes speed, according to the specified operation and the target system. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u |
The table below lists possible values for the SrcImageOrDstXLutBufId, DstImageOrYLutBufId, and OperationMode parameters.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | MIL system-specific tooltip (‡) |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
||||||||||||||||
SrcImageOrDstXLutBufId | |||||||||||||||||||||||||||||||||||||||
DstImageOrYLutBufId | |||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Performs a polar-to-rectangular transformation. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Specifies the identifier of the source image buffer containing the polar image. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
MIL system specific | |||||||||||||||||||||||||||||||||||||||
The source image buffer must be an unsigned, monochrome, 8- or 16-bit, M_BGR32 packed buffer, or a floating-point buffer. |
‡ | d | |||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the identifier of the destination buffer in which to store the transformed rectangular image. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
MIL system specific | |||||||||||||||||||||||||||||||||||||||
The destination image buffer must be unsigned monochrome 8- or 16-bit, M_BGR32 packed, or floating-point. |
‡ | d | |||||||||||||||||||||||||||||||||||||
![]() ![]() |
Generates X- and Y-coordinate LUTs for use with MimWarp() to perform the specified polar-to-rectangular transformation. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Specifies the identifier of the destination buffer in which to store the X-coordinate LUT. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Specifies the identifier of the destination buffer in which to store the Y-coordinate LUT. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Performs a rectangular-to-polar transformation. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Specifies the identifier of the source image buffer containing the rectangular image. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
MIL system specific | |||||||||||||||||||||||||||||||||||||||
The source image buffer must be an unsigned, monochrome, 8- or 16-bit, M_BGR32 packed buffer, or a floating-point buffer. |
‡ | d | |||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the identifier of the destination image buffer in which to place the transformed zone of interest. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
MIL system specific | |||||||||||||||||||||||||||||||||||||||
The destination image buffer must be unsigned monochrome 8- or 16-bit, M_BGR32 packed, or floating-point. |
‡ | d | |||||||||||||||||||||||||||||||||||||
![]() ![]() |
Generates X- and Y-coordinate LUTs for use with MimWarp() to perform the specified rectangular-to-polar transformation. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Specifies the identifier of the destination buffer in which to store the X-coordinate LUT. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | ||||||||||||||||
![]() ![]() |
Specifies the identifier of the destination buffer in which to store the Y-coordinate LUT. |
‡ | a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u |
You can add the following value to the above-mentioned values to specify the number of fractional bits in the coordinates of the source point.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the number of fractional bits for the source point ( x s , y s ). |
Header | Include mil.h. |
Library | Use mil.lib; milim.lib. |
DLL | Requires mil.dll; milim.dll. |