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
// CUDA memory handed to the DMABuf path through the fd gst_cuda_memory_export() returns (GStreamer 1.24+), instead of
4
// CUDA-GL interop. Never run on NVIDIA hardware, and not expected to import there: the fd is CUDA's shareable handle
5
// (cuMemExportToShareableHandle), which the desktop driver's EGL refuses as a dma-buf, so the path checks what it was
6
// given and turns itself off when that is no dma-buf. Only memory from a cuMemCreate pool (GST_CUDA_MEMORY_ALLOC_MMAP)
7
// can be exported at all, and nothing here asks a decoder for one. Built when HwBuffers/CMakeLists.txt finds gst-cuda
8
// and cuda.h.
9
10
#if defined(QGC_HAS_GST_CUDA_GPU_PATH)
11
12
#include <gst/gst.h>
13
#include <gst/video/video-info.h>
14
#include <memory>
15
16
#include "
GstHwVideoBufferFactory.h
"
17
18
class
GstHwVideoBuffer
;
19
20
namespace
GstCudaVideoBuffer {
21
24
bool
exportSupported() noexcept;
25
28
std::unique_ptr<GstHwVideoBuffer> exportToDmaBuf(GstSample* sample, const GstVideoInfo& info, QVideoFrameFormat format,
29
const HwVideoBufferContext& context);
30
31
}
// namespace GstCudaVideoBuffer
32
33
#endif
// QGC_HAS_GST_CUDA_GPU_PATH
GstHwVideoBufferFactory.h
GstHwVideoBuffer
Common base for GStreamer-backed QHwVideoBuffer subclasses.
Definition
GstHwVideoBuffer.h:71
src
VideoManager
GStreamer
HwBuffers
cuda
GstCudaVideoBuffer.h
Generated by
1.15.0