NVIDIA DRIVE OS Linux SDK API Reference

5.1.15.0 Release
For Test and Development only
nvmedia_vpi.h File Reference

Detailed Description

NVIDIA Media VPI Interface

Description: This file contains the NvMedia VPI API.

Definition in file nvmedia_vpi.h.

Go to the source code of this file.

Data Structures

struct  NvMediaVPIPoint2Df
 Holds 2D floating point definition. More...
 
struct  NvMediaVPIPoint2DFrac
 Holds 2D point fractional representation. More...
 
struct  NvMediaVPIAABB
 Axis Aligned Bounding Box. More...
 
struct  NvMediaVPI2DTransform
 3x3 transform matrix. More...
 
struct  NvMediaVPITranslationWithScale
 Translation with Scale parameters. More...
 
struct  NvMediaVPIBoundingBoxWithTransform
 Holds bounding box definition. More...
 
struct  NvMediaVPIStereoPostprocessParams
 Holds stereo postprocess parameters. More...
 
struct  NvMediaVPIStereoPreprocessParams
 Holds stereo preprocessing parameters. More...
 
struct  NvMediaVPIGetKeyPointsHarrisParams
 Holds Harris keypoint parameters. More...
 
struct  NvMediaVPIGetSparseFlowPyrLKParams
 NvMediaVPIGetSparseFlowPyrLKParams. More...
 
struct  NvMediaVPIKLTParams
 Holds the KLT parameters. More...
 

Macros

#define NVMEDIA_VPI_VERSION_MAJOR   3
 Major version number. More...
 
#define NVMEDIA_VPI_VERSION_MINOR   1
 Minor version number. More...
 
#define NVMEDIA_VPI_MAX_QUEUED_TASKS   (64u)
 Maximum number of tasks that can be queued. More...
 
#define NVMEDIA_VPI_CONFIDENCE_TABLE_MIN_CAPACITY   (128)
 Minimum capacity of NvMediaArray holding Confidence Table. More...
 
#define NVMEDIA_VPI_HINT_ARRAY_MIN_CAPACITY_BYTES   (261376)
 Minimum capacity (in bytes) of NvMediaArray holding Motion Vector Hints Array. More...
 

Typedefs

typedef struct NvMediaVPI NvMediaVPI
 Holds an opaque object representing NvMediaVPI. More...
 
typedef struct NvMediaVPIProcessStereoDescriptor NvMediaVPIProcessStereoDescriptor
 NvMediaVPIProcessStereo descriptor. More...
 
typedef struct NvMediaVPIConvertMVDescriptor NvMediaVPIConvertMVDescriptor
 NvMediaVPIConvertMV descriptor. More...
 
typedef struct NvMediaVPIStereoPostprocessDescriptor NvMediaVPIStereoPostprocessDescriptor
 NvMediaVPISteroPostprocess descriptor. More...
 
typedef struct NvMediaVPIStereoPreprocessDescriptor NvMediaVPIStereoPreprocessDescriptor
 NvMediaVPISteroPreprocess descriptor. More...
 
typedef struct NvMediaVPIGetKeyPointsHarrisDescriptor NvMediaVPIGetKeyPointsHarrisDescriptor
 
typedef struct NvMediaVPIGetKeyPointsFastDescriptor NvMediaVPIGetKeyPointsFastDescriptor
 
typedef struct NvMediaVPIGetSparseFlowPyrLKDescriptor NvMediaVPIGetSparseFlowPyrLKDescriptor
 NvMediaVPISparseFlowPyr descriptor. More...
 
typedef struct NvMediaVPIKLTDescriptor NvMediaVPIKLTDescriptor
 NvMediaVPIKLTDescriptor descriptor. More...
 
typedef enum NvMediaVPIKltTrackType NvMediaVPIKltTrackType
 Specifies the types of KLT Tracking. More...
 
typedef struct NvMediaVPIConvolveImageSeparableDescriptor NvMediaVPIConvolveImageSeparableDescriptor
 NvMediaVPIConvolveImageSeparableDescriptor. More...
 

Enumerations

enum  NvMediaVPIOFSTOutputType {
  NVMEDIA_VPI_STEREO_DISPARITY = 0,
  NVMEDIA_VPI_MV,
  NVMEDIA_VPI_MV_HINTS
}
 Specifies the types of output for Optical Flow/Stereo Disparity processing. More...
 
enum  NvMediaVPINonMaxSuppressionType { NVMEDIA_VPI_2D_GRID_8x8_CELL_NO_MIN_DISTANCE = 0 }
 Specifies types of post-process non-maximum suppression. More...
 
enum  NvMediaVPIHarrisGradientFilterType {
  NVMEDIA_VPI_HARRIS_FILTER_TYPE_DEFAULT = 0,
  NVMEDIA_VPI_HARRIS_FILTER_TYPE_USER
}
 Specifies types of filters used in the Harris corner detector. More...
 
enum  NvMediaVPITerminationCriterion {
  NVMEDIA_VPI_TERMINATION_CRITERION_ITERATIONS = 0,
  NVMEDIA_VPI_TERMINATION_CRITERION_EPSILON,
  NVMEDIA_VPI_TERMINATION_CRITERION_BOTH
}
 Specifies the conditions that cause the Lucas-Kanade Feature Tracker to be terminated. More...
 
enum  NvMediaVPIKltTrackType { NVMEDIA_VPI_KLT_INVERSE_COMPOSITIONAL = 0 }
 Specifies the types of KLT Tracking. More...
 

Functions

NvMediaStatus NvMediaVPIGetNumEngines (uint32_t *numEngines)
 Returns the number of HW engines accessible. More...
 
NvMediaStatus NvMediaVPIGetVersion (NvMediaVersion *version)
 Returns version information for the NvMediaVPI library. More...
 
NvMediaVPINvMediaVPICreate (const uint32_t Id, const uint32_t maxQueuedTasks)
 Creates an NvMediaVPI object. More...
 
NvMediaStatus NvMediaVPIDestroy (NvMediaVPI *vpi)
 Destroys an NvMediaVPI object created by NvMediaVPICreate(). More...
 
NvMediaStatus NvMediaVPIFlush (NvMediaVPI *vpi)
 Flushes all queued operations. More...
 
NvMediaStatus NvMediaVPIImageRegister (NvMediaVPI *vpi, NvMediaImage *image)
 Registers an image for use with an NvMediaVPI function. More...
 
NvMediaStatus NvMediaVPIImageUnregister (NvMediaVPI *vpi, NvMediaImage *image)
 Unregisters an image after use. More...
 
NvMediaStatus NvMediaVPIArrayRegister (NvMediaVPI *vpi, NvMediaArray *array)
 Registers an array for use with an NvMediaVPI function. More...
 
NvMediaStatus NvMediaVPIArrayUnregister (NvMediaVPI *vpi, NvMediaArray *array)
 Unregisters an array after use. More...
 
NvMediaStatus NvMediaVPIScratchpadRegister (NvMediaVPI *vpi, NvMediaCVScratchpad *scratchpad)
 Registers scratchpad memory for use with an NvMediaVPI function. More...
 
NvMediaStatus NvMediaVPIScratchpadUnregister (NvMediaVPI *vpi, NvMediaCVScratchpad *scratchpad)
 Unregisters scratchpad memory after use. More...
 
NvMediaStatus NvMediaVPIPyramidRegister (NvMediaVPI *vpi, NvMediaImagePyramid *pyramid)
 Registers a pyramid for use with an NvMediaVPI function. More...
 
NvMediaStatus NvMediaVPIPyramidUnregister (NvMediaVPI *vpi, NvMediaImagePyramid *pyramid)
 Unregisters a pyramid after use. More...
 
NvMediaVPIConvertMVDescriptorNvMediaVPICreateConvertMVDescriptor (NvMediaVPI *vpi, const uint32_t width, const uint32_t height, const NvMediaSurfaceType type, const float strength, const float scale)
 Creates an NvMediaVPIConvertMVDescriptor. More...
 
NvMediaStatus NvMediaVPIConvertMVDesc (NvMediaVPI *vpi, NvMediaVPIConvertMVDescriptor *descriptor, NvMediaImage *inputMVImage, NvMediaImage *inputColor, NvMediaImage *output, const NvMediaVPIOFSTOutputType outputType)
 Converts or refines a motion vector image. More...
 
NvMediaVPIStereoPostprocessDescriptorNvMediaVPICreateStereoPostprocessDescriptor (NvMediaVPI *vpi, const uint32_t width, const uint32_t height, const float scale)
 Creates an NvMediaVPIStereoPostprocessDescriptor. More...
 
NvMediaStatus NvMediaVPIStereoPostprocessDesc (NvMediaVPI *vpi, NvMediaVPIStereoPostprocessDescriptor *descriptor, NvMediaVPIStereoPostprocessParams *params, NvMediaImage *disparityInput, NvMediaImage *confidenceInput, NvMediaImage *disparityOutput, NvMediaImage *confidenceOutput)
 Performs stereo postprocessing to refine a disparity image. More...
 
NvMediaVPIStereoPreprocessDescriptorNvMediaVPICreateStereoPreprocessDescriptor (NvMediaVPI *vpi, const uint32_t width, const uint32_t height, const NvMediaVPIOFSTOutputType outputType)
 Creates an NvMediaVPIStereoPreprocessDescriptor. More...
 
NvMediaStatus NvMediaVPIStereoPreprocessDescEx (NvMediaVPI *vpi, NvMediaVPIStereoPreprocessDescriptor *descriptor, NvMediaVPIStereoPreprocessParams *params, NvMediaArray *confidenceTable, NvMediaImage *leftImage, NvMediaImage *rightImage, NvMediaImage *leftDisparity, NvMediaImage *rightDisparity, NvMediaImage *confidenceMap, NvMediaArray *hintsArray)
 Performs stereo preprocessing to produce a disparity image or motion vector hints. More...
 
NvMediaVPIGetKeyPointsHarrisDescriptorNvMediaVPICreateGetKeyPointsHarrisDescriptor (NvMediaVPI *vpi, const uint32_t width, const uint32_t height, const NvMediaVPINonMaxSuppressionType nonMaxSuppressionType)
 Creates a pointer to a NvMediaVPIGetKeyPointsHarrisDescriptor. More...
 
NvMediaStatus NvMediaVPIGetKeyPointsHarrisDesc (NvMediaVPI *vpi, NvMediaVPIGetKeyPointsHarrisDescriptor *descriptor, const NvMediaVPIGetKeyPointsHarrisParams *params, NvMediaImage *input, NvMediaImage *mask, NvMediaArray *trackedKeypoints, NvMediaArray *trackedScores, NvMediaArray *keypoints, NvMediaArray *scores)
 Queues an operation to get Harris keypoints throughout an image. More...
 
NvMediaVPIGetKeyPointsFastDescriptorNvMediaVPICreateGetKeyPointsFastDescriptor (NvMediaVPI *vpi, const uint32_t width, const uint32_t height, const NvMediaSurfaceType type)
 Creates a pointer to an NvMediaVPIGetKeyPointsFastDescriptor. More...
 
NvMediaStatus NvMediaVPIGetKeyPointsFastDesc (NvMediaVPI *vpi, NvMediaVPIGetKeyPointsFastDescriptor *descriptor, NvMediaImage *input, const uint32_t strengthThresh, const NvMediaBool nonmaxSupression, NvMediaArray *keypoints, NvMediaArray *scores)
 Queues an operation to get FAST keypoints throughout an image. More...
 
NvMediaVPIGetSparseFlowPyrLKDescriptorNvMediaVPICreateGetSparseFlowPyrLKDescriptor (NvMediaVPI *vpi, const NvMediaVPIGetSparseFlowPyrLKParams *params)
 Creates a pointer to an NvMediaVPIGetSparseFlowPyrLKDescriptor. More...
 
NvMediaStatus NvMediaVPIGetSparseFlowPyrLKDesc (NvMediaVPI *vpi, NvMediaVPIGetSparseFlowPyrLKDescriptor *descriptor, const NvMediaVPIGetSparseFlowPyrLKParams *params, NvMediaImagePyramid *oldImages, NvMediaImagePyramid *newImages, NvMediaArray *oldPoints, NvMediaArray *newPoints, NvMediaArray *newStatus)
 Queues an operation to track features in a pyramid. More...
 
NvMediaVPIKLTDescriptorNvMediaVPICreateKLTDescriptor (NvMediaVPI *vpi, const uint32_t width, const uint32_t height, const NvMediaSurfaceType type)
 Creates a pointer to the NvMediaVPIKLTDescriptor. More...
 
NvMediaStatus NvMediaVPIKLTDesc (NvMediaVPI *vpi, NvMediaVPIKLTDescriptor *descriptor, const NvMediaVPIKLTParams *params, NvMediaImage *referenceImage, NvMediaImage *templateImage, NvMediaArray *inputBoxList, NvMediaArray *predictedBoxList, NvMediaArray *outputBoxList, NvMediaArray *estimationList)
 Queues an operation to run the Kanade Lucas Tomasi (KLT) tracking algorithm. More...
 
NvMediaStatus NvMediaVPIGetScratchpadSize (void *descriptor, uint32_t *scratchpadSizeBytes)
 Returns the size of scratchpad memory required for operations that support an NvMediaCVScratchpad based scratchpad. More...
 
NvMediaStatus NvMediaVPIKLTFastDesc (NvMediaVPI *vpi, NvMediaVPIKLTDescriptor *descriptor, NvMediaCVScratchpad *scratchpad, const NvMediaVPIKLTParams *params, NvMediaImage *referenceImage, NvMediaImage *templateImage, NvMediaArray *inputBoxList, NvMediaArray *predictedBoxList, NvMediaArray *outputBoxList, NvMediaArray *estimationList)
 Queues an operation to run the Kanade Lucas Tomasi (KLT) tracking algorithm. More...
 
NvMediaStatus NvMediaVPIGetImagePyramid (NvMediaVPI *vpi, NvMediaImage *input, NvMediaImagePyramid *output)
 Queues an operation to generate a Gaussian pyramid from an input image. More...
 
NvMediaStatus NvMediaVPIConvolveImage (NvMediaVPI *vpi, NvMediaImage *input, const float *kernelData, const uint32_t kernelWidth, const uint32_t kernelHeight, NvMediaImage *output)
 Queues an operation to convolve an input image with a client-supplied convolution matrix. More...
 
NvMediaVPIConvolveImageSeparableDescriptorNvMediaVPICreateConvolveImageSeparableDescriptor (NvMediaVPI *vpi, NvMediaSurfaceType type, const float *kernelX, const uint32_t kernelXSize, const float *kernelY, const uint32_t kernelYSize)
 Creates a pointer to the NvMediaVPIConvolveImageSeparableDescriptor. More...
 
NvMediaStatus NvMediaVPIConvolveImageSeparable (NvMediaVPI *vpi, NvMediaImage *input, const float *kernelX, const uint32_t kernelXSize, const float *kernelY, const uint32_t kernelYSize, NvMediaImage *output)
 Queues an operation to convolve an image with a 2D kernel, using separable convolution. More...
 
NvMediaStatus NvMediaVPIFilterImageBox (NvMediaVPI *vpi, NvMediaImage *input, const uint32_t windowWidth, const uint32_t windowHeight, NvMediaImage *output)
 Queues an operation to compute a generic box filter window of the input image. More...
 
NvMediaStatus NvMediaVPIDestroyDescriptor (NvMediaVPI *vpi, void *descriptor)
 Destroys an NvMediaVPI function descriptor. More...