![]() |
NVIDIA DRIVE OS Linux SDK API Reference5.1.6.0 Release |
The NvMedia ICP NvSciSync API encompasses all NvMediaICP NvSciSync handling functions.
Macros | |
#define | NVMEDIA_ICP_NVSCISYNC_VERSION_MAJOR 1 |
Major version number. More... | |
#define | NVMEDIA_ICP_NVSCISYNC_VERSION_MINOR 0 |
Minor version number. More... | |
#define | NVMEDIA_ICP_MAX_PRENVSCISYNCFENCES (3) |
Maximum number of times NvMediaICPInsertPreNvSciSyncFence() may be called before each NvMediaICPFeedImageGroup call. More... | |
#define NVMEDIA_ICP_MAX_PRENVSCISYNCFENCES (3) |
Maximum number of times NvMediaICPInsertPreNvSciSyncFence() may be called before each NvMediaICPFeedImageGroup call.
Definition at line 44 of file nvmedia_icp_nvscisync.h.
#define NVMEDIA_ICP_NVSCISYNC_VERSION_MAJOR 1 |
Major version number.
Definition at line 38 of file nvmedia_icp_nvscisync.h.
#define NVMEDIA_ICP_NVSCISYNC_VERSION_MINOR 0 |
Minor version number.
Definition at line 40 of file nvmedia_icp_nvscisync.h.
NvMediaStatus NvMediaICPFillNvSciSyncAttrList | ( | NvMediaICP * | icp, |
NvSciSyncAttrList | attrlist, | ||
NvMediaNvSciSyncClientType | clienttype | ||
) |
Fills the NvMediaICP specific NvSciSync attributes.
This function assumes that attrlist is a valid NvSciSyncAttrList.
This function sets the public attributes:
The application must not set this attribute.
[in] | icp | An NvMedia ICP device handle. |
[out] | attrlist | A pointer to a structure to be filled with the NvSciSync attributes. |
[in] | clienttype | Indicates whether attrlist is requested for an NvMediaICP signaler or an NvMediaICP waiter. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that attrlist was NULL, or any of the public attributes listed above were already set. |
NVMEDIA_STATUS_OUT_OF_MEMORY | indicates that there was not enough memory for the requested operation. |
NvMediaStatus NvMediaICPGetEOFNvSciSyncFence | ( | NvMediaICP * | icp, |
const NvSciSyncObj | eofnvscisyncobj, | ||
uint32_t | channelId, | ||
NvSciSyncFence * | eofnvscisyncfence | ||
) |
Gets EOFNvSciSyncFence for a NvMediaICPFeedImageGroup() operation.
The EOFNvSciSyncFence associated with an NvMediaICPFeedImageGroup() operation is an NvSciSyncFence. Its expiry indicates that the corresponding frame capture operation has finished. NvMediaICPGetEOFNvSciSyncFence() returns the EOFNvSciSyncFence associated with the last NvMediaICPFeedImageGroup() call. NvMediaICPGetEOFNvSciSyncFence() must be called after NvMediaICPFeedImageGroup(). For example, in the below sequence of code: the last NvMediaICPFeedImageGroup() call. NvMediaICPGetEOFNvSciSyncFence() must be called after an NvMediaICPFeedImageGroup() call. For example, in the below sequence of code,
expiry of eofnvscisyncfence indicates that the preceding frame capture has finished.
[in] | icp | An NvMedia ICP device handle. |
[in] | eofnvscisyncobj | EOF NvSciSyncObj associated with the NvSciSyncFence being requested. |
[in] | channelId | Channel ID for HDR capture. |
[out] | eofnvscisyncfence | A pointer to eof NvSciSyncFence. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp was not a valid NvMediaICP handle, or that eofnvscisyncfence was NULL. |
NVMEDIA_STATUS_ERROR | indicates that the function was called before NvMediaICPFeedImageGroup(). |
NvMediaStatus NvMediaICPGetSOFNvSciSyncFence | ( | NvMediaICP * | icp, |
const NvSciSyncObj | sofnvscisyncobj, | ||
uint32_t | channelId, | ||
NvSciSyncFence * | sofnvscisyncfence | ||
) |
Gets SOF NvSciSyncFence for an NvMediaFeedImageGroup() operation.
The SOF NvSciSyncFence associated with an NvMediaICPFeedImageGroup() operation is an NvSciSyncFence. Its expiry indicates that the corresponding frame capture operation has started. NvMediaICPGetSOFNvSciSyncFence() returns the SOFNvSciSyncFence associated with the last NvMediaICPFeedImageGroup() call. You must call NvMediaICPGetSOFNvSciSyncFence() after NvMediaICPFeedImageGroup(). For example, in the below sequence of code:
expiry of sofnvscisyncfence indicates that the preceding camera capture operation has started.
[in] | icp | An NvMedia ICP device handle. |
[in] | sofnvscisyncobj | The SOF NvSciSyncObj associated with the NvSciSyncFence that is being requested. |
[in] | channelId | The channel ID for HDR capture. |
[out] | sofnvscisyncfence | A pointer to an NvSciSyncFence where SOFfence will be stored. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp is not a valid NvMediaICP handle, sofnvscisyncfence was NULL, or sofnvscisyncobj was not registered with icp as type NVMEDIA_SOFSYNCOBJ or type NVMEDIA_SOF_PRESYNCOBJ. |
NVMEDIA_STATUS_ERROR | indicates that this function was called before NvMediaICPFeedImageGroup(). |
NvMediaStatus NvMediaICPInsertPreNvSciSyncFence | ( | NvMediaICP * | icp, |
const NvSciSyncFence * | prenvscisyncfence, | ||
uint32_t | channelId | ||
) |
Sets an NvSciSyncFence as a prefence for an NvMediaICPFeedImageGroup() operation.
NvMediaICPInsertPreNvSciSyncFence() must be called before NvMediaICPFeedImageGroup() is called. The following capture operation is assured to be started only after the expiry of the prenvscisyncfence. For example, in the below sequence of code:
The image capture operation may start only after the expiry of prenvscisyncfence.
You can set a maximum of NVMEDIA_ICP_MAX_PRENVSCISYNCFENCES prefences by calling NvMediaICPInsertPreNvSciSyncFence() before calling NvMediaICPFeedImageGroup(). After the call to NvMediaICPFeedImageGroup(), all of the NvSciSyncFence objects previously inserted by NvMediaICPInsertPreNvSciSyncFence() are removed, and are not reused for the subsequent NvMediaICPFeedImageGroup() calls.
[in] | icp | NvMedia ICP device handle. |
[in] | prenvscisyncfence | A pointer to NvSciSyncFence. |
[in] | channelId | Channel ID for HDR capture. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp was not a valid NvMediaICP handle, or that prenvscisyncfence was NULL. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that NvMediaICPInsertPreNvSciSyncFence() has already been called NVMEDIA_ICP_MAX_PRENVSCISYNCFENCES or more times with the same NvMediaICP handle before a call to NvMediaICPFeedImageGroup(). |
NvMediaStatus NvMediaICPNvSciSyncGetVersion | ( | NvMediaVersion * | version | ) |
Returns version information for the NvMedia ICP NvSciSync library.
[out] | version | A pointer to a structure to be filled with version information. |
NvMediaStatus NvMediaICPRegisterNvSciSyncObj | ( | NvMediaICP * | icp, |
NvMediaNvSciSyncObjType | syncobjtype, | ||
NvSciSyncObj | syncobj, | ||
uint32_t | channelId | ||
) |
Registers an NvSciSyncObj with NvMediaICP.
Every NvSciSyncObj used by NvMediaICP (including duplicate objects) must be registered in advance by a call to this function. Only the exact same registered NvSciSyncObj can be used as an argument in NvMediaICPSetNvSciSyncObjforEOF(), NvMediaICPGetEOFNvSciSyncFence(), and NvMediaICPUnregisterNvSciSyncObj(). One NvSciSyncObj can be registered as only one NvMediaNvSciSyncObjType (see nvmedia_core.h) for a given NvMediaICP handle. A maximum of 16 NvSciSyncObj objects can be registered for each NvMediaSciSyncObjType.
[in] | icp | An NvMedia ICP device handle. |
[in] | syncobjtype | Specifies how syncobj is to be used by ICP. |
[in] | syncobj | An NvSciSyncObj to be registered with ICP. |
[in] | channelId | Channel ID for HDR capture. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp was NULL, or syncobjtype was not a valid NvMediaSciSyncObjType. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that syncobj was not a compatible NvSciSyncObj which NvMediaICP could support. |
NVMEDIA_STATUS_ERROR | indicates that the maximum allowed number of NvSciScynObj objects were already registered for the given syncobjtype, or that syncobj was already registered with the same ICP handle for a different syncobjtype. |
NvMediaStatus NvMediaICPSetNvSciSyncObjforEOF | ( | NvMediaICP * | icp, |
NvSciSyncObj | nvscisyncEOF, | ||
uint32_t | channelId | ||
) |
Set NvSciSyncObj to be used for a EOF NvSciSyncFence.
To use NvMediaICPGetEOFNvSciSyncFence(), the application must call NvMediaICPSetNvSciSyncObjforEOF() before NvMediaICPFeedImageGroup().
This function currently may be called only once before each call to NvMediaICPFeedImageGroup(). The application may choose to call this function only once before the first call to NvMediaICPFeedImageGroup().
[in] | icp | An NvMediaICP device handle. |
[in] | nvscisyncEOF | A preregistered NvSciSyncObj to be associated with EOF NvSciSyncFence. |
[in] | channelId | A channel ID for HDR capture. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp was NULL, or that nvscisyncEOF was not registered with ICP as either type NVMEDIA_EOFSYNCOBJ or type NVMEDIA_EOF_PRESYNCOBJ. |
NvMediaStatus NvMediaICPSetNvSciSyncObjforSOF | ( | NvMediaICP * | icp, |
NvSciSyncObj | nvscisyncSOF, | ||
uint32_t | channelId | ||
) |
Sets the NvSciSyncObj to be used for a SOF NvSciSyncFence.
To use NvMediaICPGetSOFNvSciSyncFence(), the application must call this function before calling NvMediaICPFeedImageGroup().
This function currently may be called only once before a call to NvMediaICPFeedImageGroup(). The application may call this function only once before the first call to NvMediaICPFeedImageGroup().
[in] | icp | An NvMedia ICP device handle. |
[in] | nvscisyncSOF | A preregistered NvSciSyncObj to be associated with SOFfence. |
[in] | channelId | Channel ID for HDR capture. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp was NULL, or that nvscisyncSOF was not registered with ICP as either type NVMEDIA_SOFSYNCOBJ or type NVMEDIA_SOF_PRESYNCOBJ. |
NvMediaStatus NvMediaICPUnregisterNvSciSyncObj | ( | NvMediaICP * | icp, |
NvSciSyncObj | syncobj, | ||
uint32_t | channelId | ||
) |
Unregisters an NvSciSyncObj with NvMediaICP.
Every NvSciSyncObj registered with NvMediaICP must be unregistered before you call NvMediaICPDestroy(). Before the application calls this function, it must ensure that the NvMediaICPGetImageGroup operation which uses the NvSciSyncObj being unregistered has completed. If this function is called while the NvSciSyncObj is still in use by an ICP operation, the result is undefined.
[in] | icp | An NvMedia ICP device handle. |
[in] | syncobj | An NvSciSyncObj to be unregistered with ICP. |
[in] | channelId | A channel ID for HDR capture. |
NVMEDIA_STATUS_OK | indicates that the call was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that icp was NULL, or that syncobj was not registered. |
NVMEDIA_STATUS_ERROR | indicates that icp has been destroyed. |