DriveWorks SDK Reference

| 0.6.67 Release

SoftISP.h
Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed
3 // under the Mutual Non-Disclosure Agreement.
4 //
5 // Notice
6 // ALL NVIDIA DESIGN SPECIFICATIONS AND CODE ("MATERIALS") ARE PROVIDED "AS IS" NVIDIA MAKES
7 // NO REPRESENTATIONS, WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
8 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ANY IMPLIED WARRANTIES OF NONINFRINGEMENT,
9 // MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
10 //
11 // NVIDIA Corporation assumes no responsibility for the consequences of use of such
12 // information or for any infringement of patents or other rights of third parties that may
13 // result from its use. No license is granted by implication or otherwise under any patent
14 // or patent rights of NVIDIA Corporation. No third party distribution is allowed unless
15 // expressly authorized by NVIDIA. Details are subject to change without notice.
16 // This code supersedes and replaces all information previously supplied.
17 // NVIDIA Corporation products are not authorized for use as critical
18 // components in life support devices or systems without express written approval of
19 // NVIDIA Corporation.
20 //
21 // Copyright (c) 2015-2017 NVIDIA Corporation. All rights reserved.
22 //
23 // NVIDIA Corporation and its licensors retain all intellectual property and proprietary
24 // rights in and to this software and related documentation and any modifications thereto.
25 // Any use, reproduction, disclosure or distribution of this software and related
26 // documentation without an express license agreement from NVIDIA Corporation is
27 // strictly prohibited.
28 //
30 
31 
132 #ifndef DW_SOFT_ISP_H__
133 #define DW_SOFT_ISP_H__
134 
135 #include <dw/core/Config.h>
136 #include <dw/core/Context.h>
137 #include <dw/core/Exports.h>
138 #include <dw/core/Types.h>
139 #include <dw/image/Image.h>
141 #include <dw/isp/Tonemap.h>
142 #include <stdint.h>
143 
144 #ifdef __cplusplus
145 extern "C" {
146 #endif
147 
150 typedef struct dwSoftISPObject *dwSoftISPHandle_t;
151 
158 
165 
166 typedef enum dwSoftISPProcessType {
174 
175 typedef struct dwSoftISPParams {
177  uint32_t width;
178  uint32_t height;
184 
196  const dwCameraProperties cameraProps);
197 
209 dwStatus dwSoftISP_initialize(dwSoftISPHandle_t *obj,
210  const dwSoftISPParams params,
211  const dwContextHandle_t ctx);
212 
222 dwStatus dwSoftISP_reset(dwSoftISPHandle_t obj);
223 
237 dwStatus dwSoftISP_release(dwSoftISPHandle_t *obj);
238 
250  dwSoftISPHandle_t obj);
251 
263  dwSoftISPHandle_t obj);
264 
278  dwSoftISPHandle_t obj);
279 
293  dwSoftISPHandle_t obj);
294 
313  dwSoftISPHandle_t obj);
314 
326 dwStatus dwSoftISP_bindRawInput(const dwImageCUDA *rawImage, dwSoftISPHandle_t obj);
327 
340 dwStatus dwSoftISP_processDeviceAsync(const int32_t type, dwSoftISPHandle_t obj);
341 
351 dwStatus dwSoftISP_setCUDAStream(cudaStream_t stream, dwSoftISPHandle_t obj);
352 
362 dwStatus dwSoftISP_getCUDAStream(cudaStream_t* stream, dwSoftISPHandle_t obj);
363 
373 dwStatus dwSoftISP_setDemosaicMethod(dwSoftISPDemosaicMethod method, dwSoftISPHandle_t obj);
374 
385 dwStatus dwSoftISP_getDemosaicMethod(dwSoftISPDemosaicMethod* method, dwSoftISPHandle_t obj);
386 
396 dwStatus dwSoftISP_setDemosaicROI(dwRect cropRegion, dwSoftISPHandle_t obj);
397 
407 dwStatus dwSoftISP_getDemosaicROI(dwRect* cropRegion, dwSoftISPHandle_t obj);
408 
409 
419 dwStatus dwSoftISP_setDenoiseMethod(dwSoftISPDenoiseMethod method, dwSoftISPHandle_t obj);
420 
431 dwStatus dwSoftISP_getDenoiseMethod(dwSoftISPDenoiseMethod* method, dwSoftISPHandle_t obj);
432 
443 dwStatus dwSoftISP_getTonemapType(dwTonemapType* type, dwSoftISPHandle_t obj);
444 
456 dwStatus dwSoftISP_setTonemapType(dwTonemapType type, dwSoftISPHandle_t obj);
457 
472  dwSoftISPHandle_t obj, cudaStream_t stream);
473 
474 #ifdef __cplusplus
475 }
476 #endif
477 
479 #endif // DW_soft_ISP_H__
Half camera resolution combining a 2x2 Bayer cell into one output pixel.
Definition: SoftISP.h:156
dwSoftISPDenoiseMethod
Definition: SoftISP.h:159
Compute tone map.
Definition: SoftISP.h:172
DW_API_PUBLIC dwStatus dwSoftISP_setDemosaicMethod(dwSoftISPDemosaicMethod method, dwSoftISPHandle_t obj)
Sets the method used to demosaic.
NVIDIA DriveWorks API: Core Types
Defines a rectangle.
Definition: Types.h:151
DW_API_PUBLIC dwStatus dwSoftISP_getBayerImageProperties(dwImageProperties *imageProperties, dwSoftISPHandle_t obj)
Gets the image properties for the produced Bayer images.
Bilateral denoising.
Definition: SoftISP.h:163
dwCameraRawFormat rawFormat
Raw pixel order.
Definition: SoftISP.h:180
Defines a CUDA image.
Definition: Image.h:263
DW_API_PUBLIC dwStatus dwSoftISP_getDemosaicROI(dwRect *cropRegion, dwSoftISPHandle_t obj)
Gets the cropping region in the Bayer image used for demosaicing.
DW_API_PUBLIC dwStatus dwSoftISP_getDenoiseMethod(dwSoftISPDenoiseMethod *method, dwSoftISPHandle_t obj)
Gets the method used for denoising.
DW_API_PUBLIC dwStatus dwSoftISP_getDemosaicMethod(dwSoftISPDemosaicMethod *method, dwSoftISPHandle_t obj)
Gets the method used for demosaic.
DW_API_PUBLIC dwStatus dwSoftISP_setTonemapType(dwTonemapType type, dwSoftISPHandle_t obj)
Sets the tonemap type.
NVIDIA DriveWorks API: Core Methods
DW_API_PUBLIC dwStatus dwSoftISP_bindBayerOutput(dwImageCUDA *bayerImage, dwSoftISPHandle_t obj)
Binds a Bayer image to the softISP.
DW_API_PUBLIC dwStatus dwSoftISP_bindDemosaicOutput(dwImageCUDA *demosaicImage, dwSoftISPHandle_t obj)
Binds a demosaic image to the softISP.
DW_API_PUBLIC dwStatus dwSoftISP_getDemosaicImageProperties(dwImageProperties *imageProperties, dwSoftISPHandle_t obj)
Gets the image properties for the produced demosaiced images.
DW_API_PUBLIC dwStatus dwSoftISP_copyTonemapCUDA(dwImageCUDA *output, const dwImageCUDA *input, dwSoftISPHandle_t obj, cudaStream_t stream)
Perform tone-mapping on demosaiced images (DEPRECATED).
NVIDIA DriveWorks API: Tonemap Types
NVIDIA DriveWorks API: Core Exports
DW_API_PUBLIC dwStatus dwSoftISP_processDeviceAsync(const int32_t type, dwSoftISPHandle_t obj)
Runs the Software ISP to convert the bound raw image into whatever output was bound beforehand...
dwSoftISPProcessType
Definition: SoftISP.h:166
uint32_t height
Definition: SoftISP.h:178
NVIDIA DriveWorks API: Image Conversion and Streaming Functionality
dwSoftISPDemosaicMethod
Definition: SoftISP.h:152
dwStatus
Status definition.
Definition: Status.h:167
dwTonemapType
Definition: Tonemap.h:45
Full camera resolution using interpolation.
Definition: SoftISP.h:154
DW_API_PUBLIC dwStatus dwSoftISP_setCUDAStream(cudaStream_t stream, dwSoftISPHandle_t obj)
Sets the CUDA stream for the softISP pipeline.
DW_API_PUBLIC dwStatus dwSoftISP_initialize(dwSoftISPHandle_t *obj, const dwSoftISPParams params, const dwContextHandle_t ctx)
Creates and initializes the software ISP pipeline.
DW_API_PUBLIC dwStatus dwSoftISP_setDemosaicROI(dwRect cropRegion, dwSoftISPHandle_t obj)
Sets the cropping region in the Bayer image used for demosaicing.
NVIDIA DriveWorks API: Cameras
DW_API_PUBLIC dwStatus dwSoftISP_getTonemapType(dwTonemapType *type, dwSoftISPHandle_t obj)
Gets the tonemap type.
DW_API_PUBLIC dwStatus dwSoftISP_setDenoiseMethod(dwSoftISPDenoiseMethod method, dwSoftISPHandle_t obj)
Sets the method used to denoise.
struct dwContextObject * dwContextHandle_t
Context handle.
Definition: Context.h:78
DW_API_PUBLIC dwStatus dwSoftISP_release(dwSoftISPHandle_t *obj)
Releases the softISP pipeline object.
struct dwSoftISPObject * dwSoftISPHandle_t
Handle representing the Software ISP.
Definition: SoftISP.h:150
uint32_t width
Size of the input image (usually the camera resolution)
Definition: SoftISP.h:177
DW_API_PUBLIC dwStatus dwSoftISP_initParamsFromCamera(dwSoftISPParams *params, const dwCameraProperties cameraProps)
Initializes the parameters for the softISP using dwCameraProperties.
DW_API_PUBLIC dwStatus dwSoftISP_bindRawInput(const dwImageCUDA *rawImage, dwSoftISPHandle_t obj)
Binds the input image to the softISP.
DW_API_PUBLIC dwStatus dwSoftISP_getCUDAStream(cudaStream_t *stream, dwSoftISPHandle_t obj)
Gets the CUDA stream for the softISP pipeline.
dwCameraRawFormat
Definition: Camera.h:71
#define DW_API_PUBLIC
Definition: Exports.h:76
DW_API_PUBLIC dwStatus dwSoftISP_reset(dwSoftISPHandle_t obj)
Resets the softISP pipeline.
dwTonemapType type
Tonemapper type (unknown for no tonemapping)
Definition: SoftISP.h:182
Defines the properties of the image.
Definition: Image.h:220
DW_API_PUBLIC dwStatus dwSoftISP_bindTonemapOutput(dwImageCUDA *tonemappedImage, dwSoftISPHandle_t obj)
Binds a tone-mapped image to the softISP.