QGIS API Documentation 3.41.0-Master (af5edcb665c)
|
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 45 of file qgsmediawidget.h.
|
explicit |
Constructor.
Definition at line 29 of file qgsmediawidget.cpp.
|
inline |
Returns the media path.
Definition at line 58 of file qgsmediawidget.h.
|
inline |
Returns the QMediaPlayer object.
Definition at line 90 of file qgsmediawidget.h.
|
inline |
Returns the media widget mode.
Definition at line 68 of file qgsmediawidget.h.
void QgsMediaWidget::setMediaPath | ( | const QString & | path | ) |
Sets the media path.
Definition at line 98 of file qgsmediawidget.cpp.
void QgsMediaWidget::setMode | ( | Mode | mode | ) |
Sets the media widget mode.
Definition at line 111 of file qgsmediawidget.cpp.
void QgsMediaWidget::setVideoHeight | ( | int | height | ) |
Sets the video frame height.
Definition at line 125 of file qgsmediawidget.cpp.
int QgsMediaWidget::videoHeight | ( | ) | const |
Returns the video frame height.
Definition at line 120 of file qgsmediawidget.cpp.