Template Class InterpolationWrap

Inheritance Relationships

Base Type

Class Documentation

template<class BW, NVCVInterpolationType I>
class InterpolationWrap : public nvcv::cuda::detail::InterpolationWrapImpl<BW, I>

Interpolation wrapper class used to wrap a BorderWrap adding interpolation handling to it.

This class wraps a BorderWrap to add interpolation handling functionality. It provides the operator[] to do the same semantic value access in the wrapped BorderWrap but interpolation aware.

using DataType = ...;
using TensorWrap2D = TensorWrap<-1, -1, DataType>;
using BorderWrap2D = BorderWrap<TensorWrap2D, NVCV_BORDER_REFLECT, true, true>;
using InterpWrap2D = InterpolationWrap<BorderWrap2D, NVCV_INTERP_CUBIC>;
TensorWrap2D tensorWrap(...);
BorderWrap2D borderWrap(...);
InterpWrap2D interpolationAwareTensor(borderWrap);
// Now use interpolationAwareTensor instead of borderWrap or tensorWrap to access in-between elements with
// on-the-fly interpolation, in this example grid-unaligned pixels use bi-cubic interpolation, grid-aligned
// pixels that fall outside the tensor use reflect border extension and inside is the tensor value itself

See also

NVCV_CPP_CUDATOOLS_INTERPOLATIONWRAPS

Note

Each interpolation wrap class below is specialized for one interpolation type.

Template Parameters: