|
static bool | resize (const FramePyramid &source, uint8_t *target, const unsigned int targetWidth, const unsigned int targetHeight, const unsigned int targetPaddingElements, Worker *worker=nullptr) |
| Resizes the finest layer of a given frame pyramid by a tri-linear interpolation and optionally uses a worker object to distribute the computational load. More...
|
|
static bool | resize (const FramePyramid &source, Frame &target, Worker *worker=nullptr) |
| Resizes the finest layer of a given frame pyramid by a tri-linear interpolation and optionally uses a worker object to distribute the computational load. More...
|
|
static bool | resize (const Frame &source, Frame &target, Worker *worker=nullptr) |
| Resizes a given frame by a tri-linear interpolation and optionally uses a worker object to distribute the computational load. More...
|
|
static bool | resize (Frame &frame, const unsigned int newWidth, const unsigned int newHeight, Worker *worker=nullptr) |
| Resizes a given frame by a tri-linear interpolation and optionally uses a worker object to distribute the computational load. More...
|
|
template<unsigned int tChannels> |
static void | homography8BitPerChannel (const FramePyramid &sourcePyramid, const unsigned int width, const unsigned int height, const SquareMatrix3 &homography, const uint8_t *borderColor, uint8_t *target, Worker *worker=nullptr) |
| Transforms a given 8 bit per channel input frame into an output frame by application of a homography. More...
|
|
static Vector3 | interpolatePosition (const unsigned int layerCount, const Vector2 ¢erPosition, const Vector2 &cornerPosition1, const Vector2 &cornerPosition2, const Vector2 &cornerPosition3, const Vector2 &cornerPosition4) |
| Calculates a 3D position usable for tri-linear interpolation. More...
|
|
template<unsigned int tChannels> |
static void | interpolateFullBorder8BitPerChannel (const FramePyramid &framePyramid, const Vector3 &position, uint8_t *result) |
| Performs a pixel lookup in the frame pyramid using tri-linear interpolation. More...
|
|
template<unsigned int tChannels, bool tAlphaAtFront, bool tTransparentIs0xFF> |
static void | interpolateInfiniteBorder8BitPerChannelAlpha (const FramePyramid &framePyramid, const Vector3 &position, uint8_t *result) |
| Performs a pixel lookup in the frame pyramid using tri-linear interpolation with infinite transparent frame border. More...
|
|
template<unsigned int tChannels> |
static void | resize8BitPerChannel (const FramePyramid &source, uint8_t *target, const unsigned int targetWidth, const unsigned int targetHeight, const unsigned int targetPaddingElements, Worker *worker=nullptr) |
| Renders the passed source frame pyramid into the target frame using tri-linear interpolation. More...
|
|
|
template<unsigned int tChannels, void tBilinearInterpolationFunction, void tLinearInterpolationFunction> |
static void | interpolate8BitPerChannel (const FramePyramid &framePyramid, const Vector3 &position, uint8_t *result) |
| Performs a pixel lookup in the frame pyramid using tri-linear interpolation. More...
|
|
template<unsigned int tChannels> |
static void | interpolateTwoPixels8BitPerChannel (const uint8_t *first, const unsigned int firstFactor, const uint8_t *second, uint8_t *result) |
| This function determines the linear interpolation result for to given layer pixels. More...
|
|
template<unsigned int tChannels, bool tAlphaAtFront, bool tTransparentIs0xFF> |
static void | interpolateTwoPixels8BitPerChannelAlpha (const uint8_t *first, const unsigned int firstFactor, const uint8_t *second, uint8_t *result) |
| This function determines the linear interpolation result for to given layer pixels while the interpolation result respects the alpha values of both pixels. More...
|
|
template<unsigned int tChannels> |
static void | resize8BitPerChannelSubset (const FramePyramid *source, uint8_t *target, const unsigned int targetWidth, const unsigned int targetHeight, const unsigned int targetPaddingElements, const unsigned int firstTargetRow, const unsigned int numberTargetRows) |
| Renders the passed source frame pyramid into the target frame using tri-linear interpolation. More...
|
|
template<unsigned int tChannels> |
static void | homography8BitPerChannelSubset (const FramePyramid *sourcePyramid, const unsigned int width, const unsigned int height, const SquareMatrix3 *homography, const uint8_t *borderColor, uint8_t *target, const unsigned int firstRow, const unsigned int numberRows) |
| Transforms an 8 bit per channel frame using the given homography. More...
|
|
This class implements tri-linear frame interpolator functions.
template<unsigned int tChannels, void tBilinearInterpolationFunction, void tLinearInterpolationFunction>
void Ocean::CV::FrameInterpolatorTrilinear::interpolate8BitPerChannel |
( |
const FramePyramid & |
framePyramid, |
|
|
const Vector3 & |
position, |
|
|
uint8_t * |
result |
|
) |
| |
|
inlinestaticprotected |
Performs a pixel lookup in the frame pyramid using tri-linear interpolation.
The position is given as 3D-vector, where x & y specify the 2d image coordinates in pixel units of the finest frame pyramid layer
and z specifies the pyramid layer index. Values with fractions for x,y & z are used as interpolation weights between neighboring pixels and layers.
- Parameters
-
framePyramid | Frame pyramid to determine the pixel values from |
position | Image coordinates (x, y) and layer (z), for which pixel values are interpolated using tri-linear interpolation within the range [0, framePyramid.finestLayerWidth()]x[0, framePyramid.finestLayerWidth()]x[0, layerCount - 1u] |
result | Pointer to resulting interpolated pixel values (1Byte per color channel) |
- Template Parameters
-
tChannels | Defines the number of channels the frame holds |
tBilinearInterpolationFunction | The bilinear interpolation function that will be used to interpolate the pixel values within one frame pyramid layer |
tLinearInterpolationFunction | The linear interpolation function that will be used to interpolate the pixel values between two frame pyramid layers |
- See also
- FrameInterpolatorBilinear::interpolatePixel8BitPerChannel(), FrameInterpolatorBilinear::interpolateFullAlphaBorder8BitPerChannel().
template<unsigned int tChannels>
void Ocean::CV::FrameInterpolatorTrilinear::interpolateFullBorder8BitPerChannel |
( |
const FramePyramid & |
framePyramid, |
|
|
const Vector3 & |
position, |
|
|
uint8_t * |
result |
|
) |
| |
|
inlinestatic |
Performs a pixel lookup in the frame pyramid using tri-linear interpolation.
The position is given as 3D-vector, where x & y specify the 2d image coordinates in pixel units of the finest frame pyramid layer
and z specifies the pyramid layer index. Values with fractions for x,y & z are used as interpolation weights between neighboring pixels and layers.
- Parameters
-
framePyramid | Frame pyramid to determine the pixel values from |
position | Image coordinates (x, y) and layer (z), for which pixel values are interpolated using tri-linear interpolation within the range [0, framePyramid.finestLayerWidth()]x[0, framePyramid.finestLayerWidth()]x[0, layerCount - 1u] |
result | Pointer to resulting interpolated pixel values (1Byte per color channel) |
- Template Parameters
-
tChannels | Defines the number of channels the frame holds |
template<unsigned int tChannels, bool tAlphaAtFront, bool tTransparentIs0xFF>
void Ocean::CV::FrameInterpolatorTrilinear::interpolateInfiniteBorder8BitPerChannelAlpha |
( |
const FramePyramid & |
framePyramid, |
|
|
const Vector3 & |
position, |
|
|
uint8_t * |
result |
|
) |
| |
|
inlinestatic |
Performs a pixel lookup in the frame pyramid using tri-linear interpolation with infinite transparent frame border.
The position is given as 3D-vector, where x & y specify the 2d image coordinates in pixel units of the finest frame pyramid layer
and z specifies the pyramid layer index. Values with fractions for x,y & z are used as interpolation weights between neighboring pixels and layers.
- Parameters
-
framePyramid | Frame pyramid to determine the pixel values from |
position | Image coordinates (x, y) and layer (z), for which pixel values are interpolated using tri-linear interpolation within the range [0, framePyramid.finestLayerWidth()]x[0, framePyramid.finestLayerWidth()]x[0, layerCount - 1u] |
result | Pointer to resulting interpolated pixel values (1Byte per color channel) |
- Template Parameters
-
tChannels | Defines the number of channels the frame holds |
tAlphaAtFront | True, if the alpha channel is in the front of the data channels |
tTransparentIs0xFF | True, if 0xFF is interpreted as fully transparent |