|
QGroundControl
Ground Control Station for MAVLink Drones
|
#include <QGCQVideoSinkController.h>
Inheritance diagram for QGCQVideoSinkController:
Collaboration diagram for QGCQVideoSinkController:Public Slots | |
| void | refreshLatency () |
Signals | |
| void | frameCountsChanged () |
| void | negotiationChanged () |
Public Member Functions | |
| QGCQVideoSinkController (GstElement *element, QObject *parent=nullptr) | |
| ~QGCQVideoSinkController () override | |
| void | setActive (bool active) |
| void | setVideoSink (QPointer< QVideoSink > sink) |
| void | prepareForRelease () |
| const GstElement * | element () const noexcept |
| void | updateNegotiation (const QString &format, const QSize &resolution) |
| quint64 | frameCount () const noexcept |
| QString | negotiatedFormat () const |
| QSize | negotiatedResolution () const |
Static Public Member Functions | |
| static QList< QGCQVideoSinkController * > | controllersOf (const QObject *receiver) |
| A receiver's owning controllers — direct children only, never a deep QObject-tree walk. | |
| static void | syncActiveToWindowVisibility (QObject *receiver, QQuickVideoOutput *videoOutput) |
GUI-thread companion for the GstQgcQVideoSink element: mirrors negotiation/telemetry into Q_PROPERTYs for QML and owns the 1 Hz timer polling frames-delivered. Driven by GstVideoReceiver's bus pump. Ownership: parent owns the controller; the controller owns one GstElement ref so deferred QObject teardown can still clear the element binding.
Definition at line 20 of file QGCQVideoSinkController.h.
| QGCQVideoSinkController::QGCQVideoSinkController | ( | GstElement * | element, |
| QObject * | parent = nullptr |
||
| ) |
element is the GstQgcQVideoSink to control. Controller takes a ref so QObject teardown can safely clear the element binding even if the parent bin is released first.
Definition at line 16 of file QGCQVideoSinkController.cc.
|
override |
Definition at line 25 of file QGCQVideoSinkController.cc.
|
static |
A receiver's owning controllers — direct children only, never a deep QObject-tree walk.
Definition at line 35 of file QGCQVideoSinkController.cc.
Referenced by GStreamer::setupQVideoSinkElement(), and syncActiveToWindowVisibility().
|
noexcept |
Definition at line 72 of file QGCQVideoSinkController.cc.
|
noexcept |
Definition at line 165 of file QGCQVideoSinkController.cc.
References delivered.
|
signal |
| QString QGCQVideoSinkController::negotiatedFormat | ( | ) | const |
Definition at line 174 of file QGCQVideoSinkController.cc.
| QSize QGCQVideoSinkController::negotiatedResolution | ( | ) | const |
Definition at line 180 of file QGCQVideoSinkController.cc.
|
signal |
Referenced by updateNegotiation().
| void QGCQVideoSinkController::prepareForRelease | ( | ) |
Stop the poll timer synchronously ahead of deleteLater so a deferred destruction can't keep binding the element while a replacement controller is installed on it. Idempotent.
Definition at line 155 of file QGCQVideoSinkController.cc.
|
slot |
Re-prime sink-side latency after a pipeline latency recalculation (e.g. RTSP jitter-buffer reconfigure). Re-queries the element latency and pushes it back.
Definition at line 101 of file QGCQVideoSinkController.cc.
References GStreamer::adoptQuery().
| void QGCQVideoSinkController::setActive | ( | bool | active | ) |
Definition at line 117 of file QGCQVideoSinkController.cc.
| void QGCQVideoSinkController::setVideoSink | ( | QPointer< QVideoSink > | sink | ) |
Definition at line 128 of file QGCQVideoSinkController.cc.
References setVideoSink().
Referenced by setVideoSink().
|
static |
Sync every controller owned by receiver to videoOutput's window visibility (drop frames while hidden/minimized), re-wiring across windowChanged. Wiring is parented to receiver.
Definition at line 41 of file QGCQVideoSinkController.cc.
References controllersOf().
Referenced by GStreamer::attachAppSink().
| void QGCQVideoSinkController::updateNegotiation | ( | const QString & | format, |
| const QSize & | resolution | ||
| ) |
Definition at line 77 of file QGCQVideoSinkController.cc.
References negotiationChanged().