QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
GStreamerSelfTestMedia.h File Reference
#include <chrono>
#include <gst/gst.h>
#include <QtCore/QByteArray>
#include <QtCore/QString>
#include <QtCore/QStringList>
#include "VideoReceiver.h"
Include dependency graph for GStreamerSelfTestMedia.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  GStreamer::SelfTest::Sample
 An encoded sample in the app's resources (Media/generate.sh makes them). More...
struct  GStreamer::SelfTest::RecordingFormat
struct  GStreamer::SelfTest::DecodeResult

Namespaces

namespace  GStreamer
namespace  GStreamer::SelfTest
 The self-test's media pipelines: decoding the embedded samples and recording and reading back a file.

Functions

bool GStreamer::SelfTest::hasDecoderFor (const Sample &sample)
 Whether decodebin3 has a decoder for sample's codec to plug: one ranked at least MARGINAL.
DecodeResult GStreamer::SelfTest::decodeSample (const Sample &sample, const QByteArray &data, std::chrono::milliseconds timeout)
 appsrc ! <parser> ! decodebin3 ! appsink, the sink taking raw video in system memory, which every decoder can give.
QString GStreamer::SelfTest::recordSample (const QString &file, VideoReceiver::FileFormat format, const QByteArray &h264, std::chrono::milliseconds timeout)
 appsrc ! RecordingBranch's file sink (h264parse ! muxer ! filesink), as a recording is muxed.
QString GStreamer::SelfTest::readBack (const QString &file, const char *demuxer, std::chrono::milliseconds timeout)
 filesrc ! <demuxer> ! fakesink: the recorded file opens and holds video.

Variables

constexpr Sample GStreamer::SelfTest::kH264Sample {"H.264", ":/gstreamer/selftest/h264_160x120.h264", "video/x-h264", "h264parse"}
constexpr Sample GStreamer::SelfTest::kH265Sample {"H.265", ":/gstreamer/selftest/h265_320x240.h265", "video/x-h265", "h265parse"}
constexpr RecordingFormat GStreamer::SelfTest::kRecordingFormats []