QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
GstCudaVideoBuffer.h
Go to the documentation of this file.
1#pragma once
2
3// SCAFFOLD — requires NVIDIA hardware to validate; gated behind QGC_HAS_GST_CUDA_GPU_PATH (never defined by CMake yet).
4// CUDA/NVMM buffers are routed by exporting the device memory to a DMABuf fd and reusing the DMABuf EGLImage path
5// rather than CUDA-GL interop. Enabling this requires CMake gating for gst/cuda/gstcuda.h (gst-plugins-bad CUDA) and a
6// Jetson/desktop-NVIDIA test pass.
7
8#if defined(QGC_HAS_GST_CUDA_GPU_PATH)
9
10#include <gst/gst.h>
11#include <gst/video/video-info.h>
12#include <memory>
13
15
17
18namespace GstCudaVideoBuffer {
19
23std::unique_ptr<GstHwVideoBuffer> exportToDmaBuf(GstSample* sample, const GstVideoInfo& info, QVideoFrameFormat format,
24 const HwVideoBufferContext& context);
25
26} // namespace GstCudaVideoBuffer
27
28#endif // QGC_HAS_GST_CUDA_GPU_PATH
Common base for GStreamer-backed QHwVideoBuffer subclasses.
Platform context for the factory; encapsulates EGL handles so callers don't need path-specific ifdefs...