class VideoPlayer
Video playback with compact controls, captions and fullscreen. Link shadcn::media to use this optional component.
A native build decodes with Qt Multimedia. The WebAssembly build has no Qt Multimedia to link, so the browser decodes and the transport, timeline, settings menu and every control stay in C++. See docs/components/video-player.md for what differs.
Inherits from QWidget
Functions
audioOutput
public QAudioOutput & audioOutput()
Borrowed audio output, owned by this widget.
VideoPlayer
public VideoPlayer(QWidget * parent)
player
public QMediaPlayer & player()
Borrowed playback backend, owned by this widget.
~VideoPlayer
public void ~VideoPlayer()
setSource
public void setSource(const QUrl & source)
isFullScreen
public bool isFullScreen()
setFullScreen
public void setFullScreen(bool enabled)
sizeHint
public QSize sizeHint()
fullScreenChanged
public void fullScreenChanged(bool enabled)
eventFilter
protected bool eventFilter(QObject * watched, QEvent * event)