|
QGroundControl
Ground Control Station for MAVLink Drones
|
#include <QtMultimedia/QVideoFrame>#include <QtMultimedia/QVideoFrameFormat>#include <gst/gst.h>#include <gst/video/video-info.h>#include <gst/video/video.h>#include "HwBuffers/common/HwBuffers.h"
Include dependency graph for GStreamerFrameMap.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Classes | |
| struct | MappedFrame |
Functions | |
| QVideoFrameFormat::ColorSpace | toQtColorSpace (GstVideoColorMatrix matrix) |
| Sample-to-frame helpers for qgcqvideosink's show_frame; pure functions, streaming-thread safe. | |
| QVideoFrameFormat::ColorTransfer | toQtColorTransfer (GstVideoTransferFunction transfer) |
| QVideoFrameFormat::PixelFormat | toQtPixelFormat (GstVideoFormat fmt) |
| QVideoFrameFormat::ColorRange | toQtColorRange (GstVideoColorRange range) |
| void | applyOrientationToFrame (QVideoFrame &frame, GstVideoOrientationMethod method) |
| Apply rotation + mirror flags derived from GstVideoOrientationMethod. | |
| void | applyOrientationAndTiming (QVideoFrame &frame, GstBuffer *buffer, int streamOrientation) |
| void | applyColorimetry (QVideoFrameFormat &format, const GstVideoInfo &info, GstCaps *caps) |
| QVideoFrameFormat | applyCropMeta (QVideoFrameFormat format, GstBuffer *buffer) |
Apply video crop meta to format's viewport. Pass-through when no crop meta present. | |
| MappedFrame | mapSampleToFrame (GstBuffer *buffer, GstCaps *caps, const GstVideoInfo &info, const QVideoFrameFormat &format, const HwVideoBufferContext &hwContext, HwResolvedPathCache *pathCache=nullptr) noexcept |
| void applyColorimetry | ( | QVideoFrameFormat & | format, |
| const GstVideoInfo & | info, | ||
| GstCaps * | caps | ||
| ) |
Set color-space/transfer/range from gst-video colorimetry + HDR (MaxCLL preferred); infers BT.601/709 from height when caps omit it.
Definition at line 164 of file GStreamerFrameMap.cc.
References toQtColorRange(), toQtColorSpace(), and toQtColorTransfer().
Referenced by gst_qgc_q_video_sink_set_caps().
| QVideoFrameFormat applyCropMeta | ( | QVideoFrameFormat | format, |
| GstBuffer * | buffer | ||
| ) |
Apply video crop meta to format's viewport. Pass-through when no crop meta present.
Definition at line 211 of file GStreamerFrameMap.cc.
Referenced by gst_qgc_q_video_sink_show_frame().
| void applyOrientationAndTiming | ( | QVideoFrame & | frame, |
| GstBuffer * | buffer, | ||
| int | streamOrientation | ||
| ) |
Per-frame orientation (meta wins, else stream fallback) + PTS/duration timing; streamOrientation is GstVideoOrientationMethod cast to int.
Definition at line 140 of file GStreamerFrameMap.cc.
References applyOrientationToFrame().
Referenced by gst_qgc_q_video_sink_show_frame().
| void applyOrientationToFrame | ( | QVideoFrame & | frame, |
| GstVideoOrientationMethod | method | ||
| ) |
Apply rotation + mirror flags derived from GstVideoOrientationMethod.
Definition at line 93 of file GStreamerFrameMap.cc.
Referenced by applyOrientationAndTiming().
|
noexcept |
Definition at line 219 of file GStreamerFrameMap.cc.
References CpuVideoFramePool::copyFromBuffer(), MappedFrame::Cpu, MappedFrame::frame, MappedFrame::Gpu, makeHwVideoBuffer(), None, MappedFrame::source, and CpuVideoFramePool::wrapZeroCopy().
Referenced by gst_qgc_q_video_sink_show_frame().
| QVideoFrameFormat::ColorRange toQtColorRange | ( | GstVideoColorRange | range | ) |
Definition at line 79 of file GStreamerFrameMap.cc.
Referenced by applyColorimetry().
| QVideoFrameFormat::ColorSpace toQtColorSpace | ( | GstVideoColorMatrix | matrix | ) |
Sample-to-frame helpers for qgcqvideosink's show_frame; pure functions, streaming-thread safe.
Definition at line 16 of file GStreamerFrameMap.cc.
Referenced by applyColorimetry().
| QVideoFrameFormat::ColorTransfer toQtColorTransfer | ( | GstVideoTransferFunction | transfer | ) |
Definition at line 35 of file GStreamerFrameMap.cc.
Referenced by applyColorimetry().
| QVideoFrameFormat::PixelFormat toQtPixelFormat | ( | GstVideoFormat | fmt | ) |
Definition at line 69 of file GStreamerFrameMap.cc.
References GstQgc::kVideoFormatTable.
Referenced by gst_qgc_q_video_sink_set_caps().