ResizeSqrPixel

Resize and shift an image

Supported Technologies

SSE2

Synopsis

FwStatus   fwiResizeSqrPixel_8u_C1R ( const Fw8u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw8u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_8u_C3R ( const Fw8u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw8u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_8u_C4R ( const Fw8u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw8u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_8u_AC4R ( const Fw8u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw8u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_16u_C1R ( const Fw16u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw16u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_16u_C3R ( const Fw16u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw16u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_16u_C4R ( const Fw16u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw16u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_16u_AC4R ( const Fw16u * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw16u * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_32f_C1R ( const Fw32f * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw32f * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_32f_C3R ( const Fw32f * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw32f * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_32f_C4R ( const Fw32f * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw32f * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_32f_AC4R ( const Fw32f * pSrcFwiSize srcSizeint srcStepFwiRect srcRoiFw32f * pDstint dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_8u_P3R ( const Fw8u * const pSrc[3]FwiSize srcSizeint srcStepFwiRect srcRoiFw8u * const pDst[3]int dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_8u_P4R ( const Fw8u * const pSrc[4]FwiSize srcSizeint srcStepFwiRect srcRoiFw8u * const pDst[4]int dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_16u_P3R ( const Fw16u * const pSrc[3]FwiSize srcSizeint srcStepFwiRect srcRoiFw16u * const pDst[3]int dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_16u_P4R ( const Fw16u * const pSrc[4]FwiSize srcSizeint srcStepFwiRect srcRoiFw16u * const pDst[4]int dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_32f_P3R ( const Fw32f * const pSrc[3]FwiSize srcSizeint srcStepFwiRect srcRoiFw32f * const pDst[3]int dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );
FwStatus   fwiResizeSqrPixel_32f_P4R ( const Fw32f * const pSrc[4]FwiSize srcSizeint srcStepFwiRect srcRoiFw32f * const pDst[4]int dstStepFwiRect dstRoidouble xFactordouble yFactordouble xShiftdouble yShiftint interpolationFw8u * pBuffer );

Parameters

dstRoi   Destination image ROI.
dstStep   Destination buffer step size (width of the buffer in bytes).
interpolation   Specifies the method of interpolation.
pBuffer   Pointer to the location of a temporary buffer.
pDst   Pointer to a location in a destination buffer.
pDst[3]   Pointer to a location in a three-channel planar destination buffer (array values point to a location in each plane).
pDst[4]   Pointer to a location in a four-channel planar destination buffer (array values point to a location in each plane).
pSrc   Pointer to a location in a source buffer.
pSrc[3]   Pointer to a location in a three-channel planar source buffer (array values point to a location in each plane).
pSrc[4]   Pointer to a location in a four-channel planar source buffer (array values point to a location in each plane).
srcRoi   Source image ROI.
srcSize   Source image size.
srcStep   Source buffer step size (width of the buffer in bytes).
xFactor   Factor value for X axis direction.
xShift   Shift value for X axis direction.
yFactor   Factor value for Y axis direction .
yShift   Shift value for Y axis direction.

Description

These functions step through an ROI in a source buffer, scale the source data using x-y scaling factors and a specified method of interpolation, then shift the data to a destination ROI.

Unlike the ResizeShift function, the ResizeSqrPixel functions map the source ROI to a specified destination ROI and use noninverted x-y scaling factors.

The functions use the following mapping formulas.

 x'=x*xFactor+xShift
 y'=y*yFactor+yShift

The following interpolation modes are available.

 FWI_INTER_NN: nearest neighbor interpolation
 FWI_INTER_LINEAR: linear interpolation
 FWI_INTER_CUBIC: cubic interpolation
 FWI_INTER_SUPER: supersampling
 PLI_INTER_LANCZOS: interpolation with Lanczos window function

Use the super-sampling interpolation option when both the x and y scaling factors are less than 1.