Template Class BorderVarShapeWrapNHWC

Inheritance Relationships

Base Type

Class Documentation

template<typename T, NVCVBorderType B>
class BorderVarShapeWrapNHWC : public nvcv::cuda::detail::BorderIWImpl<T, B>

Public Types

using ImageBatchWrapper = IW
using ValueType = typename ImageBatchWrapper::ValueType

Public Functions

BorderVarShapeWrapNHWC() = default
inline explicit __host__ __device__ BorderVarShapeWrapNHWC (ImageBatchWrapper imageBatchWrap, ValueType borderValue={})

Constructs a BorderVarShapeWrapNHWC by wrapping an imageBatchWrap.

Parameters:
  • imageBatchWrap[in] An ImageBatchVarShapeWrapNHWC object to be wrapped.

  • borderValue[in] The border value is ignored in non-constant border types.

inline explicit __host__ BorderVarShapeWrapNHWC(const ImageBatchVarShapeDataStridedCuda &images, int numChannels, ValueType borderValue = {})

Constructs a BorderVarShapeWrapNHWC by wrapping images.

Parameters:
  • images[in] A ImageBatchVarShapeDataStridedCuda with image batch information.

  • numChannels[in] The number of (interleaved) channels inside the wrapper.

  • borderValue[in] The border value is ignored in non-constant border types.

inline __host__ __device__ ValueType & operator[] (int4 c) const

Subscript operator for read-only or read-and-write access (depending on value type).

Parameters:

c[in] 4D coordinates (x sample, y row, z col, w channel) to be accessed.

Returns:

Accessed (const) reference.

inline __host__ __device__ ValueType & operator[] (int3 c) const

Subscript operator for read-only or read-and-write access (depending on value type, considering plane=0).

Parameters:

c[in] 3D coordinates (x sammple, y row, z col) (first channel) to be accessed.

Returns:

Accessed (const) reference.

inline __host__ __device__ ValueType * ptr (int s, int y, int x, int c) const

Get a read-only or read-and-write proxy (as pointer) at the given coordinates.

Parameters:
  • s[in] Sample image index in the list.

  • y[in] Row index in the selected image.

  • x[in] Column index in the selected image.

  • c[in] Channel index in the image.

Returns:

The (const) pointer to the beginning of the given coordinates.

inline __host__ __device__ ValueType * ptr (int s, int y, int x) const

Get a read-only or read-and-write proxy (as pointer) at the given coordinates (considering plane=0).

Parameters:
  • s[in] Sample image index in the list.

  • y[in] Row index in the selected image.

  • x[in] Column index in the selected image.

Returns:

The (const) pointer to the beginning of the given coordinates.

inline const __host__ __device__ ImageBatchWrapper & imageBatchWrap () const

Public Static Attributes

static constexpr NVCVBorderType kBorderType
static constexpr int kNumDimensions