NVIDIA DRIVE OS Linux API Reference

5.1.3.0 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Image Display Processing (IDP)

Detailed Description

Displays NvMediaImage type surfaces.

Data Structures

struct  NvMediaIDP
 Image display object created by NvMediaIDPCreate. More...
 
struct  NvMediaIDPPreferences
 Sets the preferences for the image display creation. More...
 
struct  NvMediaIDPDeviceParams
 Device parameters returned by NvMediaIDPQuery function. More...
 

Macros

#define NVMEDIA_IDP_VERSION_MAJOR   2
 Major Version number. More...
 
#define NVMEDIA_IDP_VERSION_MINOR   0
 Minor Version number. More...
 

Functions

NvMediaStatus NvMediaIDPGetVersion (NvMediaVersion *version)
 Gets the version compatibility for the NvMedia IDP library. More...
 
NvMediaIDPNvMediaIDPCreate (uint32_t displayId, uint32_t windowId, NvMediaIDPPreferences *displayPreference, NvMediaBool alreadyCreated)
 Creates an image display object. More...
 
void NvMediaIDPDestroy (NvMediaIDP *idp)
 Destroy an image display object created by NvMediaIDPCreate. More...
 
NvMediaStatus NvMediaIDPSetAttributes (NvMediaIDP *idp, uint32_t attributeMask, NvMediaDispAttributes *attributes)
 Set NvMediaIDP attributes. More...
 
NvMediaStatus NvMediaIDPQuery (int32_t *displayDevices, NvMediaIDPDeviceParams *displayParams)
 Queries the display system and returns the parameters of all display devices. More...
 
NvMediaStatus NvMediaIDPFlip (NvMediaIDP *idp, NvMediaImage *image, NvMediaRect *srcRect, NvMediaRect *dstRect, NvMediaImage **releaseList, NvMediaTime *timeStamp)
 Displays an image on the display device. More...
 

Macro Definition Documentation

#define NVMEDIA_IDP_VERSION_MAJOR   2

Major Version number.

Definition at line 36 of file nvmedia_idp.h.

#define NVMEDIA_IDP_VERSION_MINOR   0

Minor Version number.

Definition at line 38 of file nvmedia_idp.h.

Function Documentation

NvMediaIDP* NvMediaIDPCreate ( uint32_t  displayId,
uint32_t  windowId,
NvMediaIDPPreferences displayPreference,
NvMediaBool  alreadyCreated 
)

Creates an image display object.

Parameters
[in]displayIdDisplay id (head) of the device.
[in]windowIdSpecifies the h/w overlay window to access. ex: (windowId = 0) == (Overlay Window A). Valid values are 0 (A), 1 (B), 2 (C).
[in]displayPreferenceDesired display parameters. To use defaults set it to NULL.
[in]alreadyCreatedSet to NVMEDIA_TRUE if the dislpay is already created (initialized) by another application. In this case NvMedia is not going to create a new one just reuse it.
Returns
NvMediaIDP The new image display's handle or NULL if unsuccessful. The width, hight and refreshRate members reflect the actual display parameter values.
void NvMediaIDPDestroy ( NvMediaIDP idp)

Destroy an image display object created by NvMediaIDPCreate.

Parameters
[in]idpThe display to be destroyed.
Returns
void
NvMediaStatus NvMediaIDPFlip ( NvMediaIDP idp,
NvMediaImage image,
NvMediaRect srcRect,
NvMediaRect dstRect,
NvMediaImage **  releaseList,
NvMediaTime timeStamp 
)

Displays an image on the display device.

Parameters
[in]idpThe display device object.
[in]imageThe image to be displayed.
[in]srcRectSource rectangle. If NULL, a rectangle of the full size of the NvMediaImage is implied.
[in]dstRectDestination rectangle on the display. If NULL, a rectangle of the full size of the display device is implied. Note: Scaling is not supported for RGB type images and dstRect acts as a crop rectangle.
[in]releaseListPoints to an array of NvMediaImage pointers filled by this function and terminated with NULL. When NvMediaIDPFlip function is called it might need to use some of the input images for a longer time depending on the pipelining model. When the images are no longer needed they are released using this list. It is the application responsibility to allocate the memory for the list. The maximum size of the list is 2 including the one for the NULL terminator.
[in]timeStampDetermines when the image is going to be displayed. This is a pointer to the time structure. NULL means the image is displayed as soon as possible.
Returns
NvMediaStatus Status of the display flip operation. Possible values are:
NVMEDIA_STATUS_OK
NVMEDIA_STATUS_BAD_PARAMETER
NvMediaStatus NvMediaIDPGetVersion ( NvMediaVersion version)

Gets the version compatibility for the NvMedia IDP library.

Parameters
[in]versionA pointer to a NvMediaVersion structure of the client.
Returns
NvMediaStatus The status of the operation. Possible values are:
NVMEDIA_STATUS_OK
NVMEDIA_STATUS_BAD_PARAMETER if the pointer is invalid.
NvMediaStatus NvMediaIDPQuery ( int32_t *  displayDevices,
NvMediaIDPDeviceParams displayParams 
)

Queries the display system and returns the parameters of all display devices.

If displayParams is NULL then only displayDevices is returned and this way the client can query the number of devices, allocate memory for the descriptors and call this function again with the properly allocated displayParams buffer.

Parameters
[out]displayDevicesSet by the function to the number of display devices.
[out]displayParamsThis parameters is used as an array and the function fills it up with displayDevices number of entries. It is the client's responsibility to allocate sufficient memory. If NULL no data is returned.
Returns
NvMediaStatus The completion status of the operation. Possible values are:
NVMEDIA_STATUS_OK
NVMEDIA_STATUS_BAD_PARAMETER
NvMediaStatus NvMediaIDPSetAttributes ( NvMediaIDP idp,
uint32_t  attributeMask,
NvMediaDispAttributes attributes 
)

Set NvMediaIDP attributes.

Parameters
[in]idpImage display object
[in]attributeMaskDetermines which attributes are set. The value can be any combination of the binary OR of the following attributes:
NVMEDIA_DISP_ATTR_BRIGHTNESS
NVMEDIA_DISP_ATTR_CONTRAST
NVMEDIA_DISP_ATTR_SATURATION
NVMEDIA_DISP_ATTR_HUE
NVMEDIA_DISP_ATTR_COLOR_STANDARD
NVMEDIA_DISP_ATTR_LIMITED_RGB
NVMEDIA_DISP_ATTR_COMPOSITION
NVMEDIA_DISP_ATTR_SET_DEPTH
[in]attributesA pointer to a structure that holds all the attributes but only those are used which are indicated in the attributeMask.
Returns
NvMediaStatus The completion status of the operation. Possible values are:
NVMEDIA_STATUS_OK
NVMEDIA_STATUS_BAD_PARAMETER if any of the input parameters is invalid.