QGIS API Documentation 3.41.0-Master (fda2aa46e9a)
|
The QgsMediaWidget class creates a widget for playing back audio and video media files. More...
#include <qgsmediawidget.h>
Public Types | |
enum | Mode { Audio , Video } |
The mode determines the user interface elements visible within the widget. More... | |
Public Member Functions | |
QgsMediaWidget (QWidget *parent=nullptr) | |
Constructor. | |
QString | mediaPath () const |
Returns the media path. | |
QMediaPlayer * | mediaPlayer () |
Returns the QMediaPlayer object. | |
Mode | mode () const |
Returns the media widget mode. | |
void | setMediaPath (const QString &path) |
Sets the media path. | |
void | setMode (Mode mode) |
Sets the media widget mode. | |
void | setVideoHeight (int height) |
Sets the video frame height. | |
int | videoHeight () const |
Returns the video frame height. | |
The QgsMediaWidget class creates a widget for playing back audio and video media files.
Definition at line 37 of file qgsmediawidget.h.
enum QgsMediaWidget::Mode |
The mode determines the user interface elements visible within the widget.
Enumerator | |
---|---|
Audio | Audio-centric user interface. |
Video | Video-centric user interface. |
Definition at line 47 of file qgsmediawidget.h.
|
explicit |
Constructor.
Definition at line 29 of file qgsmediawidget.cpp.
|
inline |
Returns the media path.
Definition at line 60 of file qgsmediawidget.h.
|
inline |
Returns the QMediaPlayer object.
Definition at line 92 of file qgsmediawidget.h.
|
inline |
Returns the media widget mode.
Definition at line 70 of file qgsmediawidget.h.
void QgsMediaWidget::setMediaPath | ( | const QString & | path | ) |
Sets the media path.
Definition at line 101 of file qgsmediawidget.cpp.
void QgsMediaWidget::setMode | ( | Mode | mode | ) |
Sets the media widget mode.
Definition at line 114 of file qgsmediawidget.cpp.
void QgsMediaWidget::setVideoHeight | ( | int | height | ) |
Sets the video frame height.
Definition at line 128 of file qgsmediawidget.cpp.
int QgsMediaWidget::videoHeight | ( | ) | const |
Returns the video frame height.
Definition at line 123 of file qgsmediawidget.cpp.