Defines the image transformation module.
Data Structures | |
struct | dwImageTransformationParameters |
Typedefs | |
typedef struct dwImageTransformationObject * | dwImageTransformationHandle_t |
The image transformation handle. More... | |
Enumerations | |
enum | dwImageProcessingBorderMode { DW_IMAGEPROCESSING_BORDER_MODE_ZERO = 0 , DW_IMAGEPROCESSING_BORDER_MODE_MIRROR = 1 , DW_IMAGEPROCESSING_BORDER_MODE_REPEAT = 2 , DW_IMAGEPROCESSING_BORDER_MODE_WRAP = 3 } |
Border mode (valid for DW_IMAGE_CUDA types) More... | |
enum | dwImageProcessingInterpolation { DW_IMAGEPROCESSING_INTERPOLATION_DEFAULT , DW_IMAGEPROCESSING_INTERPOLATION_LINEAR , DW_IMAGEPROCESSING_INTERPOLATION_POINT } |
Interpolation mode. More... | |
Functions | |
DW_API_PUBLIC dwStatus | dwImageTransformation_addPrefenceWait (const NvSciSyncFence *syncFence, dwImageTransformationHandle_t handle) |
Add prefence for NvMedia2D to wait. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_appendAllocationAttributes (dwImageProperties *const imgProps, dwImageTransformationHandle_t handle) |
Append the allocation attribute such that the images created of type DW_IMAGE_NVMEDIA can be fed to dwImageTransformation_copy, dwImageTransformation_copySubImage and dwImageTransformation_copyFullImage functions. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_copy (dwImageHandle_t outputImage, const dwImageHandle_t inputImage, const dwRect *outputROI, const dwRect *inputROI, dwImageTransformationHandle_t handle) |
Resizes the input image subregion and copies the result into the previously allocated output image, in a specified subregion, of the same type (CUDA or NvMedia) and format (any) More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_copyFullImage (dwImageHandle_t const outputImage, dwImageHandle_t const inputImage, dwImageTransformationHandle_t const handle) |
Resizes the input image and copies the result into the previously allocated output image, of the same type (CUDA or NvMedia) and format (any) More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_copySubImage (dwImageHandle_t const outputImage, dwImageHandle_t const inputImage, dwRect const inputROI, dwImageTransformationHandle_t const handle) |
Resizes the input image sub region and copies the result into the previously allocated output image, of the same type (CUDA or NvMedia) and format (any) More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_fillNvSciSyncAttrs (NvSciSyncAttrList syncAttrList, dwSyncType syncType, dwImageTransformationHandle_t handle) |
Fill the sync attributes for the imagetransformation to signal EOF fences. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_getCUDAStream (cudaStream_t *stream, dwImageTransformationHandle_t handle) |
Gets the cuda stream used by the APIs of Image Transformation. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_getEOFFence (NvSciSyncFence *syncFence, dwImageTransformationHandle_t handle) |
Get EOF fence of the current operation. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_initialize (dwImageTransformationHandle_t *handle, dwImageTransformationParameters params, dwContextHandle_t context) |
Initializes an Image Transformation Engine with the given parameters. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_registerImages (dwImagePool imagePool, dwImageTransformationHandle_t handle) |
All (both input and output) images that the transformation engine has to work with (NvMedia2D VIC mode only) must be placed in a dwImagePool and registered during initialization phase Note that all the images must have been created with properties with allocation attributes set. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_release (dwImageTransformationHandle_t handle) |
Releases the passed Transformation Engine, deallocating all the resources used. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_reset (dwImageTransformationHandle_t handle) |
Resets an Image Transformation Engine. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_setBorderMode (dwImageProcessingBorderMode mode, dwImageTransformationHandle_t handle) |
Sets the border mode used by the APIs of Image Transformation. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_setCUDAStream (cudaStream_t stream, dwImageTransformationHandle_t handle) |
Sets the cuda stream used by the APIs of Image Transformation. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_setInterpolationMode (dwImageProcessingInterpolation mode, dwImageTransformationHandle_t handle) |
Sets the interpolation mode used by the APIs of Image Transformation. More... | |
DW_API_PUBLIC dwStatus | dwImageTransformation_setNvSciSyncObj (NvSciSyncObj syncObj, dwSyncType syncType, dwImageTransformationHandle_t handle) |
Set the sync obj to which the imagetransformation will signal EOF fences. More... | |
struct dwImageTransformationParameters |
typedef struct dwImageTransformationObject* dwImageTransformationHandle_t |
The image transformation handle.
Definition at line 60 of file ImageTransformation.h.
Border mode (valid for DW_IMAGE_CUDA types)
Definition at line 65 of file ImageProcessingCommon.h.
Interpolation mode.
Definition at line 55 of file ImageProcessingCommon.h.
DW_API_PUBLIC dwStatus dwImageTransformation_addPrefenceWait | ( | const NvSciSyncFence * | syncFence, |
dwImageTransformationHandle_t | handle | ||
) |
Add prefence for NvMedia2D to wait.
[out] | syncFence | The sync fence of the frame |
[in] | handle | Handle to imagetransformation |
DW_API_PUBLIC dwStatus dwImageTransformation_appendAllocationAttributes | ( | dwImageProperties *const | imgProps, |
dwImageTransformationHandle_t | handle | ||
) |
Append the allocation attribute such that the images created of type DW_IMAGE_NVMEDIA can be fed to dwImageTransformation_copy, dwImageTransformation_copySubImage and dwImageTransformation_copyFullImage functions.
[in,out] | imgProps | Image properties |
[in] | handle | dwImageTransformation handle |
DW_API_PUBLIC dwStatus dwImageTransformation_copy | ( | dwImageHandle_t | outputImage, |
const dwImageHandle_t | inputImage, | ||
const dwRect * | outputROI, | ||
const dwRect * | inputROI, | ||
dwImageTransformationHandle_t | handle | ||
) |
Resizes the input image subregion and copies the result into the previously allocated output image, in a specified subregion, of the same type (CUDA or NvMedia) and format (any)
[out] | outputImage | Pointer to the output image. |
[in] | inputImage | Pointer to the input image. |
[in] | outputROI | Pointer to a ROI on the output image where to copy the result. If null, defaults to the full image |
[in] | inputROI | Pointer to a ROI on the input image, where the source pixels are located. If null, defaults to the full image |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_copyFullImage | ( | dwImageHandle_t const | outputImage, |
dwImageHandle_t const | inputImage, | ||
dwImageTransformationHandle_t const | handle | ||
) |
Resizes the input image and copies the result into the previously allocated output image, of the same type (CUDA or NvMedia) and format (any)
[out] | outputImage | Pointer to the output image. |
[in] | inputImage | Pointer to the input image. |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_copySubImage | ( | dwImageHandle_t const | outputImage, |
dwImageHandle_t const | inputImage, | ||
dwRect const | inputROI, | ||
dwImageTransformationHandle_t const | handle | ||
) |
Resizes the input image sub region and copies the result into the previously allocated output image, of the same type (CUDA or NvMedia) and format (any)
[out] | outputImage | Pointer to the output image. |
[in] | inputImage | Pointer to the input image. |
[in] | inputROI | Pointer to a ROI on the input image, where the source pixels are located. |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_fillNvSciSyncAttrs | ( | NvSciSyncAttrList | syncAttrList, |
dwSyncType | syncType, | ||
dwImageTransformationHandle_t | handle | ||
) |
Fill the sync attributes for the imagetransformation to signal EOF fences.
Note that multiple calls on the same syncAttrList will append the same attributes.
[out] | syncAttrList | The sync attributes list to be filled |
[in] | syncType | The sync type |
[in] | handle | The imagetransformation handle |
DW_API_PUBLIC dwStatus dwImageTransformation_getCUDAStream | ( | cudaStream_t * | stream, |
dwImageTransformationHandle_t | handle | ||
) |
Gets the cuda stream used by the APIs of Image Transformation.
[out] | stream | CUDA stream |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_getEOFFence | ( | NvSciSyncFence * | syncFence, |
dwImageTransformationHandle_t | handle | ||
) |
Get EOF fence of the current operation.
[out] | syncFence | The sync fence of the frame |
[in] | handle | Handle to imagetransformation |
DW_API_PUBLIC dwStatus dwImageTransformation_initialize | ( | dwImageTransformationHandle_t * | handle, |
dwImageTransformationParameters | params, | ||
dwContextHandle_t | context | ||
) |
Initializes an Image Transformation Engine with the given parameters.
[out] | handle | Pointer to the Image Transformation Engine |
[in] | params | parameters of image transformation. |
[in] | context | Handle to Driveworks |
DW_API_PUBLIC dwStatus dwImageTransformation_registerImages | ( | dwImagePool | imagePool, |
dwImageTransformationHandle_t | handle | ||
) |
All (both input and output) images that the transformation engine has to work with (NvMedia2D VIC mode only) must be placed in a dwImagePool and registered during initialization phase Note that all the images must have been created with properties with allocation attributes set.
[in] | imagePool | Handle to the dwImagePool, ownership remains of the creator of the pool |
[in] | handle | dwImageTransformation handle |
DW_API_PUBLIC dwStatus dwImageTransformation_release | ( | dwImageTransformationHandle_t | handle | ) |
Releases the passed Transformation Engine, deallocating all the resources used.
[in] | handle | Pointer to the Image Transformation Engine. |
DW_API_PUBLIC dwStatus dwImageTransformation_reset | ( | dwImageTransformationHandle_t | handle | ) |
Resets an Image Transformation Engine.
[in] | handle | Pointer to the Image Transformation Engine. |
DW_API_PUBLIC dwStatus dwImageTransformation_setBorderMode | ( | dwImageProcessingBorderMode | mode, |
dwImageTransformationHandle_t | handle | ||
) |
Sets the border mode used by the APIs of Image Transformation.
[in] | mode | Border mode |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_setCUDAStream | ( | cudaStream_t | stream, |
dwImageTransformationHandle_t | handle | ||
) |
Sets the cuda stream used by the APIs of Image Transformation.
[in] | stream | CUDA stream |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_setInterpolationMode | ( | dwImageProcessingInterpolation | mode, |
dwImageTransformationHandle_t | handle | ||
) |
Sets the interpolation mode used by the APIs of Image Transformation.
[in] | mode | Interpolation mode |
[in] | handle | Handle to the Image Transformation engine |
DW_API_PUBLIC dwStatus dwImageTransformation_setNvSciSyncObj | ( | NvSciSyncObj | syncObj, |
dwSyncType | syncType, | ||
dwImageTransformationHandle_t | handle | ||
) |
Set the sync obj to which the imagetransformation will signal EOF fences.
The sync object is not reference counted.
[in] | syncObj | The sync object |
[in] | syncType | The sync type |
[in] | handle | The imagetransformation handle |