NVIDIA DriveOS Linux NSR SDK API Reference

7.0.3.0 Release
FrameCapture.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: Copyright (c) 2019-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3  * SPDX-License-Identifier: LicenseRef-NvidiaProprietary
4  *
5  * NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
6  * property and proprietary rights in and to this material, related
7  * documentation and any modifications thereto. Any use, reproduction,
8  * disclosure or distribution of this material and related documentation
9  * without an express license agreement from NVIDIA CORPORATION or
10  * its affiliates is strictly prohibited.
11  */
12 
29 #ifndef DW_FRAMECAPTURE_H_
30 #define DW_FRAMECAPTURE_H_
31 
32 #include <dw/sensors/common/SensorSerializer.h>
33 
34 #include "Image.h"
35 
36 #include <nvscisync.h>
37 
38 #ifdef __cplusplus
39 extern "C" {
40 #endif
41 
45 typedef struct dwFrameCaptureObject* dwFrameCaptureHandle_t;
46 
48 typedef enum dwFrameCaptureMode {
54 
58 typedef struct
59 {
61  uint32_t width;
62 
64  uint32_t height;
65 
71 
73  uint32_t mode;
74 
77 
80 
87 
105  dwSALHandle_t sal,
107 
121 
136 dwStatus dwFrameCapture_screenCapture(const dwImageGL** imageGL, const dwRect roi,
137  dwFrameCaptureHandle_t framecapture);
138 
151  dwFrameCaptureHandle_t framecapture);
152 
164 
175 DW_DEPRECATED("dwFrameCapture_appendFrameCUDA: this function is deprecated, replace with the dwFrameCapture_appendFrame")
177 
178 #ifndef VIBRANTE
179 
190 #else
191 
201 dwStatus dwFrameCapture_appendFrameNvMedia(const dwImageNvMedia* img, dwFrameCaptureHandle_t framecapture);
209 dwStatus dwFrameCapture_fillSyncAttributes(NvSciSyncAttrList syncAttrList, dwFrameCaptureHandle_t framecapture);
210 
218 dwStatus dwFrameCapture_setSyncObject(NvSciSyncObj syncObj, dwFrameCaptureHandle_t framecapture);
219 
228 dwStatus dwFrameCapture_insertFence(NvSciSyncFence* syncFence, dwFrameCaptureHandle_t framecapture);
229 
230 #endif
231 
243 
269  dwFrameCaptureHandle_t framecapture);
270 #ifdef __cplusplus
271 }
272 #endif
273 
274 #endif // DW_FRAMECAPTURE_H_
dwImageGL
Defines a GL texture image.
Definition: Image_1.h:42
NvSciSyncObj
struct NvSciSyncObjRec * NvSciSyncObj
Definition: wfdext.h:86
DW_FRAMECAPTURE_MODE_SERIALIZE
@ DW_FRAMECAPTURE_MODE_SERIALIZE
Serialize enables the creation of the serializer which allows the calls to dwFrameCapture_appendFrame...
Definition: FrameCapture.h:52
dwFrameCaptureParams::serializeGL
bool serializeGL
Boolean, if true it serializes DW_IMAGE_GL only, otherwise all other serializations (CUDA/CPU on X86,...
Definition: FrameCapture.h:76
dwFrameCapture_appendFrameCUDA
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_appendFrameCUDA(const dwImageCUDA *img, dwFrameCaptureHandle_t framecapture)
Append a dwImageCUDA frame to the capture and it's serialized.
ctx
DW_API_PUBLIC dwPointCloudRangeImageCreatorParams const *const const dwContextHandle_t ctx
Definition: PointCloudRangeImageCreator.h:293
dwFrameCapture_appendFrameCPU
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_appendFrameCPU(const dwImageCPU *img, dwFrameCaptureHandle_t framecapture)
Append a dwImageCPU frame to the capture and it's serialized.
dwImageCPU
Defines a CPU-based image.
Definition: Image.h:494
dwFrameCaptureParams
Initialization parameters for the frame capture module.
Definition: FrameCapture.h:58
dwFrameCaptureMode
dwFrameCaptureMode
Enables FrameCapture functionalities. These can be set as a logical OR between the two modes....
Definition: FrameCapture.h:48
nvscisync.h
NVIDIA Software Communications Interface (SCI) : NvSciSync
dwImageNvMedia
Defines an NvMedia image.
Definition: Image.h:524
DW_FRAMECAPTURE_MODE_SCREENCAP
@ DW_FRAMECAPTURE_MODE_SCREENCAP
Screencapture mode allocates GL resources that enable the capture of the current rendering Window via...
Definition: FrameCapture.h:50
dwFrameCapture_appendFrame
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_appendFrame(const dwImageHandle_t img, dwFrameCaptureHandle_t framecapture)
Append a dwImageHandle frame to the capture and it's serialized.
dwImageCUDA
Defines a CUDA image.
Definition: Image.h:508
dwRect
Defines a rectangle.
Definition: GeometricTypes.h:47
dwFrameCaptureParams::setupForDirectCameraOutput
bool setupForDirectCameraOutput
Boolean, if it is true and MUST use dwFrameCapture_appendAllocationAttributes to append nvsciBufAttrL...
Definition: FrameCapture.h:85
dwFrameCaptureParams::params
dwSerializerParams params
SensorSerializer parameters, see SensorSerializer.h.
Definition: FrameCapture.h:79
dwFrameCaptureParams::mode
uint32_t mode
Logic OR of the dwFrameCaptureMode. Can be either or all. Useful for not allocating useless resources...
Definition: FrameCapture.h:73
dwFrameCaptureHandle_t
struct dwFrameCaptureObject * dwFrameCaptureHandle_t
Handle to a Frame Capture module object.
Definition: FrameCapture.h:45
Image.h
dwFrameCapture_screenCapture
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_screenCapture(const dwImageGL **imageGL, const dwRect roi, dwFrameCaptureHandle_t framecapture)
It grabs what is currently rendered on the current frame buffer and returns a dwImageGL out of it For...
dwFrameCapture_release
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_release(dwFrameCaptureHandle_t framecapture)
Releases the frame capture module.
DW_DEPRECATED
#define DW_DEPRECATED(msg)
Definition: Exports.h:50
dwSerializerParams
Holds the parameters for sensor serializer creation.
Definition: SensorSerializerTypes.h:90
dwFrameCapture_appendFrameGL
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_appendFrameGL(const dwImageGL *img, dwFrameCaptureHandle_t framecapture)
Append a dwImageGL frame to the capture and it's serialized.
dwImageProperties
Defines the properties of the image.
Definition: Image.h:477
dwContextHandle_t
struct dwContextObject * dwContextHandle_t
Context handle.
Definition: Context.h:74
dwFrameCaptureParams::width
uint32_t width
Width of the GL window / image.
Definition: FrameCapture.h:61
dwFrameCaptureParams::captureCustom
bool captureCustom
The frameCaptured image is returned as a dwImageGL.
Definition: FrameCapture.h:70
NvSciSyncFence
Defines the opaque NvSciSyncFence.
Definition: nvscisync.h:256
dwSALHandle_t
struct dwSALObject * dwSALHandle_t
Handle representing the Sensor Abstraction Layer interface.
Definition: SensorTypes.h:39
dwImageHandle_t
struct dwImageObject * dwImageHandle_t
Definition: Image.h:88
dwStatus
dwStatus
Status definition.
Definition: ErrorDefs.h:27
dwFrameCaptureParams::height
uint32_t height
Height of the GL window / image.
Definition: FrameCapture.h:64
NvSciSyncAttrList
struct NvSciSyncAttrListRec * NvSciSyncAttrList
Definition: wfdext.h:88
params
DW_API_PUBLIC dwPointCloudRangeImageCreatorParams const *const params
Definition: PointCloudRangeImageCreator.h:292
DW_API_PUBLIC
#define DW_API_PUBLIC
Definition: Exports.h:38
obj
const NvSciSyncObj *const obj
Definition: wfdext.h:120
dwFrameCapture_screenCaptureCustom
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_screenCaptureCustom(dwImageGL *imageGL, const dwRect roi, dwFrameCaptureHandle_t framecapture)
It grabs what is currently rendered on the current frame buffer and blits onto the input dwImageGL.
dwFrameCapture_initialize
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_initialize(dwFrameCaptureHandle_t *obj, const dwFrameCaptureParams *params, dwSALHandle_t sal, dwContextHandle_t ctx)
Create a new frame capture module.
DW_VIZ_API_PUBLIC
#define DW_VIZ_API_PUBLIC
Definition: Exports_1.h:31
dwFrameCapture_appendAllocationAttributes
DW_API_PUBLIC dwStatus dwFrameCapture_appendAllocationAttributes(dwImageProperties *imgProps, dwFrameCaptureHandle_t framecapture)
Append the allocation attribute to create images that work with other NvSci based modules.