NVIDIA DRIVE OS Linux SDK API Reference

5.1.6.0 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
NvSciBuf Enumerations for Attribute Keys

Detailed Description

List of all NvSciBuf enumerations for attribute keys.

Enumerations

enum  NvSciBufAttrKey {
  NvSciBufAttrKey_LowerBound = NV_SCI_BUF_GENERAL_ATTR_KEY_START,
  NvSciBufGeneralAttrKey_Types,
  NvSciBufGeneralAttrKey_NeedCpuAccess,
  NvSciBufGeneralAttrKey_RequiredPerm,
  NvSciBufGeneralAttrKey_EnableCpuCache,
  NvSciBufGeneralAttrKey_GpuId,
  NvSciBufGeneralAttrKey_CpuNeedSwCacheCoherency,
  NvSciBufGeneralAttrKey_ActualPerm,
  NvSciBufRawBufferAttrKey_Size = NV_SCI_BUF_RAW_BUF_ATTR_KEY_START,
  NvSciBufRawBufferAttrKey_Align,
  NvSciBufImageAttrKey_Layout = NV_SCI_BUF_IMAGE_ATTR_KEY_START,
  NvSciBufImageAttrKey_TopPadding,
  NvSciBufImageAttrKey_BottomPadding,
  NvSciBufImageAttrKey_LeftPadding,
  NvSciBufImageAttrKey_RightPadding,
  NvSciBufImageAttrKey_VprFlag,
  NvSciBufImageAttrKey_Size,
  NvSciBufImageAttrKey_Alignment,
  NvSciBufImageAttrKey_PlaneCount,
  NvSciBufImageAttrKey_PlaneColorFormat,
  NvSciBufImageAttrKey_PlaneColorStd,
  NvSciBufImageAttrKey_PlaneBaseAddrAlign,
  NvSciBufImageAttrKey_PlaneWidth,
  NvSciBufImageAttrKey_PlaneHeight,
  NvSciBufImageAttrKey_PlaneScanType,
  NvSciBufImageAttrKey_ScanType = NvSciBufImageAttrKey_PlaneScanType,
  NvSciBufImageAttrKey_PlaneBitsPerPixel,
  NvSciBufImageAttrKey_PlaneOffset,
  NvSciBufImageAttrKey_PlaneDatatype,
  NvSciBufImageAttrKey_PlaneChannelCount,
  NvSciBufImageAttrKey_PlaneSecondFieldOffset,
  NvSciBufImageAttrKey_PlanePitch,
  NvSciBufImageAttrKey_PlaneAlignedHeight,
  NvSciBufImageAttrKey_PlaneAlignedSize,
  NvSciBufTensorAttrKey_DataType = NV_SCI_BUF_TENSOR_ATTR_KEY_START,
  NvSciBufTensorAttrKey_NumDims,
  NvSciBufTensorAttrKey_SizePerDim,
  NvSciBufTensorAttrKey_AlignmentPerDim,
  NvSciBufTensorAttrKey_StridesPerDim,
  NvSciBufArrayAttrKey_DataType = NV_SCI_BUF_ARRAY_ATTR_KEY_START,
  NvSciBufArrayAttrKey_Stride,
  NvSciBufArrayAttrKey_Capacity,
  NvSciBufArrayAttrKey_Size,
  NvSciBufArrayAttrKey_Alignment,
  NvSciBufPyramidAttrKey_NumLevels = NV_SCI_BUF_PYRAMID_ATTR_KEY_START,
  NvSciBufPyramidAttrKey_Scale,
  NvSciBufPyramidAttrKey_LevelOffset,
  NvSciBufPyramidAttrKey_LevelSize,
  NvSciBufAttrKey_UpperBound
}
 Describes the public attribute keys. More...
 

Enumeration Type Documentation

Describes the public attribute keys.

Enumerator
NvSciBufAttrKey_LowerBound 

Specifies the lower bound value to check for a valid NvSciBuf attribute key type.

NvSciBufGeneralAttrKey_Types 

Specifies the buffer type that the attribute list is expected to have.

For each type the buffer has, the associated attributes are valid.

Type: Input attribute

Datatype: NvSciBufType

NvSciBufGeneralAttrKey_NeedCpuAccess 

Specifies if CPU access is required.

If this attribute is set to true, then the CPU will be able to obtain a pointer to the buffer from NvSciBufObjGetCpuPtr().

Type: Input attribute

Datatype: bool

NvSciBufGeneralAttrKey_RequiredPerm 

Specifies which access permissions are required.

If NvSciBufGeneralAttrKey_NeedCpuAccess is true, the pointer returned by NvSciBufObjGetCpuPtr() will provide these permissions. Any hardware accelerators that contribute to this attribute list will be offered at least these permissions.

Type: Input attribute

Datatype: NvSciBufAttrValAccessPerm

NvSciBufGeneralAttrKey_EnableCpuCache 

Specifies whether to enable/disable CPU caching.

If set to true:

The CPU must perform write-back caching of the buffer to the greatest extent possible considering all the CPUs that are sharing the buffer. Coherency is guaranteed with:

  • Other CPU accessors.
  • All I/O-Coherent accessors that do not have CPU-invisible caches.

If set to false:

The CPU must not access the caches at all on read or write accesses to the buffer from applications. Coherency is guaranteed with:

  • Other CPU accessors.
  • All I/O accessors (whether I/O-coherent or not) that do not have CPU-invisible caches.

Type: Input attribute

Datatype: bool

NvSciBufGeneralAttrKey_GpuId 

GpuIDs of the GPUs in the system that will access the buffer.

In a multi GPU System, if multiple GPUs are supposed to access the buffer, then provide the GPU IDs of all the GPUs that need to access the buffer. The GPU which is not specified in the list of GPUIDs may not be able to access the buffer.

Type: Input attribute

Datatype: uint64_t[]

NvSciBufGeneralAttrKey_CpuNeedSwCacheCoherency 

Indicates whether the CPU is required to flush before reads and after writes.

This can be accomplished using NvSciBufObjFlushRange(), or (if the application prefers) with OS-specific flushing functions.

Type: Output attribute

Datatype: bool

NvSciBufGeneralAttrKey_ActualPerm 

Specifies the access permissions that are provided.

This key can only be used after reconciliation to find out the access permissions provided to the ipcEndpoint which has imported this attribute list. Any hardware accelerators that contribute to this attribute list will be offered at least these permissions.

Type: Output attribute

Datatype: NvSciBufAttrValAccessPerm

NvSciBufRawBufferAttrKey_Size 

Specifies the size of the buffer to allocate.

Type: Input attribute

Datatype: uint64_t

NvSciBufRawBufferAttrKey_Align 

Specifies the alignment requirement of raw buffer.

Type: Input attribute

Datatype: uint64_t

NvSciBufImageAttrKey_Layout 

Specifies the layout: Block-linear or Pitch-linear.

Type: Input/Output attribute

Datatype: NvSciBufAttrValImageLayoutType

NvSciBufImageAttrKey_TopPadding 

Specifies the top padding for the image.

Type: Input/Output attribute

Datatype: uint64_t

NvSciBufImageAttrKey_BottomPadding 

Specifies the bottom padding for the image.

Type: Input/Output attribute

Datatype: uint64_t

NvSciBufImageAttrKey_LeftPadding 

Specifies the left padding for the image.

Type: Input/Output attribute

Datatype: uint64_t

NvSciBufImageAttrKey_RightPadding 

Specifies the right padding for the image.

Type: Input/Output attribute

Datatype: uint64_t

NvSciBufImageAttrKey_VprFlag 

Specifies the VPR flag for the image.

Type: Input attribute

Datatype: bool

NvSciBufImageAttrKey_Size 

Indicates the size of the image.

Type: Output attribute

Datatype: uint64_t

NvSciBufImageAttrKey_Alignment 

Indicates the alignment for the image.

Type: Output attribute

Datatype: uint64_t

NvSciBufImageAttrKey_PlaneCount 

Specifies the number of image planes.

Type: Input/Output attribute

Datatype: uint32_t

NvSciBufImageAttrKey_PlaneColorFormat 

Specifies the color format of the image plane.

Type: Input/Output attribute

Dataype: NvSciBufAttrValColorFmt[]

NvSciBufImageAttrKey_PlaneColorStd 

Specifies a set of plane color standards.

Type: Input/Output attribute

Dataype: NvSciBufAttrValColorStd[]

NvSciBufImageAttrKey_PlaneBaseAddrAlign 

Specifies the image plane base address alignment.

Type: Input/Output attribute

Datatype: int32_t[]

NvSciBufImageAttrKey_PlaneWidth 

Specifies the image plane width in pixels.

Type: Input/Output attribute

Datatype: int32_t[]

NvSciBufImageAttrKey_PlaneHeight 

Specifies the image plane height in pixels.

Type: Input/Output attribute

Datatype: int32_t[]

NvSciBufImageAttrKey_PlaneScanType 

Specifies the image scan type: Progressive or Interlaced.

Type: Input attribute

Datatype: NvSciBufAttrValImageScanType

NvSciBufImageAttrKey_ScanType 
NvSciBufImageAttrKey_PlaneBitsPerPixel 

Indicates the image plane in bits per pixel.

Type: Output attribute

Datatype: uint32_t[]

NvSciBufImageAttrKey_PlaneOffset 

Indicates the starting offset of the image plane.

Type: Output attribute

Datatype: uint64_t[]

NvSciBufImageAttrKey_PlaneDatatype 

Indicates the color format of the image plane.

Type: Output attribute

Datatype: NvSciBufAttrValDataType

NvSciBufImageAttrKey_PlaneChannelCount 

Indicates the channel count in the image plane.

Type: Output attribute

Datatype: uint8_t

NvSciBufImageAttrKey_PlaneSecondFieldOffset 

Indicates the offset of the start of the second field, 0 for progressive valid for interlaced.

Type: Output attribute

Datatype: int64_t[]

NvSciBufImageAttrKey_PlanePitch 

Indicates the pitch of the image plane.

Type: Output attribute

Datatype: int32_t[]

NvSciBufImageAttrKey_PlaneAlignedHeight 

Indicates the aligned height of the image plane.

Type: Output attribute

Datatype: int32_t[]

NvSciBufImageAttrKey_PlaneAlignedSize 

Indicates the aligned size of the image plane.

Type: Output attribute

Datatype: int64_t[]

NvSciBufTensorAttrKey_DataType 

Specifies the tensor data type.

Type: Input attribute

Datatype: NvSciBufAttrValDataType

NvSciBufTensorAttrKey_NumDims 

Specifies the number of tensor dimensions.

A maximum of 8 dimensions are allowed.

Type: Input attribute

Datatype: int32_t

NvSciBufTensorAttrKey_SizePerDim 

Specifies the size of each tensor dimension.

This attribute takes size value in terms of an array.

Note
Array indices are not tied to the semantics of the dimension. NvSciBuf is not affected by the dimension order.

Type: Input attribute

Datatype: uint64_t[]

NvSciBufTensorAttrKey_AlignmentPerDim 

Specifies the alignment constraints per tensor dimension.

Type: Input attribute

Datatype: uint32_t[]

NvSciBufTensorAttrKey_StridesPerDim 

Returns the stride value (in bytes) for each tensor dimension.

Note
The returned array contains stride values in decreasing order. In other words, the index 0 of the array will have the largest stride while [number-of-dims - 1] index will have the smallest stride.

Type: Output attribute

Datatype: uint64_t[]

NvSciBufArrayAttrKey_DataType 

Specifies the data type of a buffer array.

Type: Input attribute

Datatype: NvSciBufAttrValDataType

NvSciBufArrayAttrKey_Stride 

Specifies the stride of each element in the buffer array.

Stride must be less than the size of the array data type.

Type: Input attribute

Datatype: uint64_t

NvSciBufArrayAttrKey_Capacity 

Specifies the buffer array capacity.

Type: Input attribute

Datatype: uint64_t

NvSciBufArrayAttrKey_Size 

Indicates the total size of a buffer array.

Type: Output attribute

Datatype: uint64_t

NvSciBufArrayAttrKey_Alignment 

Indicates the base alignment of a buffer array.

Type: Output attribute

Datatype: uint64_t

NvSciBufPyramidAttrKey_NumLevels 

Specifies the number of levels of images in a pyramid.

Type: Input attribute

Datatype: uint32_t

NvSciBufPyramidAttrKey_Scale 

Specifies the scaling factor by which each successive image in a pyramid must be scaled.

Value must be 0 < scale <= 1.

Type: Input attribute

Datatype: float

NvSciBufPyramidAttrKey_LevelOffset 

NvSciBuf allocates the total buffer size considering all levels in an image pyramid and returns an array of buffer offsets for each level.

Type: Output attribute

Datatype: uint64_t[]

NvSciBufPyramidAttrKey_LevelSize 

NvSciBuf allocates the total buffer size considering all levels in an image pyramid and returns an array of buffer sizes for each level.

Type: Output attribute

Datatype: uint64_t[]

NvSciBufAttrKey_UpperBound 

Specifies the maximum number of NvSciBuf attribute keys.

The total space for keys is 32K.

Datatype: None

Definition at line 271 of file nvscibuf.h.