DriveWorks SDK Reference
5.10.90 Release
For Test and Development only

FrameCapture.h
Go to the documentation of this file.
1
2//
3// Notice
4// ALL NVIDIA DESIGN SPECIFICATIONS AND CODE ("MATERIALS") ARE PROVIDED "AS IS" NVIDIA MAKES
5// NO REPRESENTATIONS, WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
6// THE MATERIALS, AND EXPRESSLY DISCLAIMS ANY IMPLIED WARRANTIES OF NONINFRINGEMENT,
7// MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
8//
9// NVIDIA CORPORATION & AFFILIATES assumes no responsibility for the consequences of use of such
10// information or for any infringement of patents or other rights of third parties that may
11// result from its use. No license is granted by implication or otherwise under any patent
12// or patent rights of NVIDIA CORPORATION & AFFILIATES. No third party distribution is allowed unless
13// expressly authorized by NVIDIA. Details are subject to change without notice.
14// This code supersedes and replaces all information previously supplied.
15// NVIDIA CORPORATION & AFFILIATES products are not authorized for use as critical
16// components in life support devices or systems without express written approval of
17// NVIDIA CORPORATION & AFFILIATES.
18//
19// SPDX-FileCopyrightText: Copyright (c) 2019-2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
20// SPDX-License-Identifier: LicenseRef-NvidiaProprietary
21//
22// NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
23// property and proprietary rights in and to this material, related
24// documentation and any modifications thereto. Any use, reproduction,
25// disclosure or distribution of this material and related documentation
26// without an express license agreement from NVIDIA CORPORATION or
27// its affiliates is strictly prohibited.
28//
30
47#ifndef DW_FRAMECAPTURE_H_
48#define DW_FRAMECAPTURE_H_
49
51
52#include "Image.h"
53
54#include <nvscisync.h>
55
56#ifdef __cplusplus
57extern "C" {
58#endif
59
63typedef struct dwFrameCaptureObject* dwFrameCaptureHandle_t;
64
66typedef enum dwFrameCaptureMode {
72
76typedef struct
77{
79 uint32_t width;
80
82 uint32_t height;
83
89
91 uint32_t mode;
92
95
98
105
122 const dwFrameCaptureParams* params,
123 dwSALHandle_t sal,
125
139
155 dwFrameCaptureHandle_t framecapture);
156
169 dwFrameCaptureHandle_t framecapture);
170
182
193DW_DEPRECATED("dwFrameCapture_appendFrameCUDA: this function is deprecated, replace with the dwFrameCapture_appendFrame")
195
196#ifndef VIBRANTE
207dwStatus dwFrameCapture_appendFrameCPU(const dwImageCPU* img, dwFrameCaptureHandle_t framecapture);
208#else
227dwStatus dwFrameCapture_fillSyncAttributes(NvSciSyncAttrList syncAttrList, dwFrameCaptureHandle_t framecapture);
228
237
246dwStatus dwFrameCapture_insertFence(NvSciSyncFence* syncFence, dwFrameCaptureHandle_t framecapture);
247
248#endif
249
261
287 dwFrameCaptureHandle_t framecapture);
288#ifdef __cplusplus
289}
290#endif
292#endif // DW_FRAMECAPTURE_H_
Defines a rectangle.
NVIDIA DriveWorks API: Sensor Serializer
struct dwContextObject * dwContextHandle_t
Context handle.
Definition: Context.h:83
#define DW_DEPRECATED(msg)
Definition: Exports.h:66
#define DW_API_PUBLIC
Definition: Exports.h:54
dwStatus
Status definition.
Definition: Status.h:173
uint32_t height
Height of the GL window / image.
Definition: FrameCapture.h:82
dwSerializerParams params
SensorSerializer parameters, see SensorSerializer.h.
Definition: FrameCapture.h:97
uint32_t width
Width of the GL window / image.
Definition: FrameCapture.h:79
bool setupForDirectCameraOutput
Boolean, if it is true and MUST use dwFrameCapture_appendAllocationAttributes to append nvsciBufAttrL...
Definition: FrameCapture.h:103
bool serializeGL
Boolean, if true it serializes DW_IMAGE_GL only, otherwise all other serializations (CUDA/CPU on X86,...
Definition: FrameCapture.h:94
uint32_t mode
Logic OR of the dwFrameCaptureMode. Can be either or all. Useful for not allocating useless resources...
Definition: FrameCapture.h:91
bool captureCustom
The frameCaptured image is returned as a dwImageGL.
Definition: FrameCapture.h:88
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_release(dwFrameCaptureHandle_t framecapture)
Releases the frame capture module.
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...
struct dwFrameCaptureObject * dwFrameCaptureHandle_t
Handle to a Frame Capture module object.
Definition: FrameCapture.h:63
dwFrameCaptureMode
Enables FrameCapture functionalities. These can be set as a logical OR between the two modes....
Definition: FrameCapture.h:66
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_fillSyncAttributes(NvSciSyncAttrList syncAttrList, dwFrameCaptureHandle_t framecapture)
Fill the sync attributes for the encoder to signal EOF fences.
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 dwStatus dwFrameCapture_appendFrameGL(const dwImageGL *img, dwFrameCaptureHandle_t framecapture)
Append a dwImageGL frame to the capture and it's serialized.
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.
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_setSyncObject(NvSciSyncObj syncObj, dwFrameCaptureHandle_t framecapture)
Set the sync obj to which the encoder will wait on SOF fences.
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.
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_appendFrameNvMedia(const dwImageNvMedia *img, dwFrameCaptureHandle_t framecapture)
Append a dwImageNvMedia frame to the capture and it's serialized.
DW_API_PUBLIC dwStatus dwFrameCapture_insertFence(NvSciSyncFence *syncFence, dwFrameCaptureHandle_t framecapture)
Insert fence to wait on completed operations.
DW_VIZ_API_PUBLIC dwStatus dwFrameCapture_appendFrameCUDA(const dwImageCUDA *img, dwFrameCaptureHandle_t framecapture)
Append a dwImageCUDA frame to the capture and it's serialized.
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.
@ DW_FRAMECAPTURE_MODE_SERIALIZE
Serialize enables the creation of the serializer which allows the calls to dwFrameCapture_appendFrame...
Definition: FrameCapture.h:70
@ DW_FRAMECAPTURE_MODE_SCREENCAP
Screencapture mode allocates GL resources that enable the capture of the current rendering Window via...
Definition: FrameCapture.h:68
Initialization parameters for the frame capture module.
Definition: FrameCapture.h:77
Defines a GL texture image.
Definition: Image.h:61
struct dwImageObject * dwImageHandle_t
Definition: Image.h:102
Defines a CPU-based image.
Definition: Image.h:407
Defines a CUDA image.
Definition: Image.h:420
Defines an NvMedia image.
Definition: Image.h:436
Defines the properties of the image.
Definition: Image.h:390
Holds the parameters for sensor serializer creation.
struct dwSALObject * dwSALHandle_t
Handle representing the Sensor Abstraction Layer interface.
Definition: Sensors.h:83
#define DW_VIZ_API_PUBLIC
Definition: Exports.h:49
NVIDIA DriveWorks GL API: Image Conversion and Streaming Functionality