15#ifndef QWASMVIDEOOUTPUT_H
16#define QWASMVIDEOOUTPUT_H
20#include <emscripten/val.h>
21#include <QMediaPlayer>
25#include <QtCore/qloggingcategory.h>
27#include <private/qstdweb_p.h>
78 void setHasAudio(
bool needsAudio) { m_hasAudio = needsAudio; }
102 void checkNetworkState();
103 void videoComputeFrame(
void *
context);
104 void getDeviceSettings();
108 emscripten::val m_video = emscripten::val::undefined();
109 emscripten::val m_videoElementSource = emscripten::val::undefined();
112 float m_requestedPosition = 0.0;
113 emscripten::val m_offscreen = emscripten::val::undefined();
115 bool m_shouldStop =
false;
116 bool m_toBePaused =
false;
117 bool m_isSeeking =
false;
118 bool m_hasAudio =
false;
119 bool m_cameraIsReady =
false;
121 emscripten::val m_offscreenContext = emscripten::val::undefined();
122 QSize m_pendingVideoSize;
125 qreal m_currentBufferedValue;
\inmodule QtCore \reentrant
QObject * parent() const
Returns a pointer to the parent object.
\inmodule QtCore\reentrant
\macro QT_RESTRICTED_CAST_FROM_ASCII
The QVideoFrame class represents a frame of video data.
The QVideoSink class represents a generic sink for video data.
void addCameraSourceElement(const std::string &id)
void updateVideoElementGeometry(const QRect &windowGeometry)
bool setDeviceSetting(const std::string &key, emscripten::val value)
void sizeChange(qint32 width, qint32 height)
void newFrame(const QVideoFrame &newFrame)
emscripten::val surfaceElement()
void durationChanged(qint64 duration)
emscripten::val getDeviceCapabilities()
static void videoFrameCallback(emscripten::val now, emscripten::val metadata)
void setVideoSize(const QSize &)
void setMuted(bool muted)
void setSource(const QUrl &url)
void setVideoMode(QWasmVideoOutput::WasmVideoMode mode)
void bufferingChanged(qint32 percent)
void seekTo(qint64 position)
void setVolume(qreal volume)
void createVideoElement(const std::string &id)
void stateChanged(QWasmMediaPlayer::QWasmMediaPlayerState newState)
void setSurface(QVideoSink *surface)
bool hasCapability(const QString &cap)
void removeSourceElement()
void statusChanged(QMediaPlayer::MediaStatus status)
void progressChanged(qint32 position)
void errorOccured(qint32 code, const QString &message)
qint64 getCurrentPosition()
void setPlaybackRate(qreal rate)
void setHasAudio(bool needsAudio)
void doElementCallbacks()
void addSourceElement(const QString &urlString)
void createOffscreenElement(const QSize &offscreenSize)
void videoFrameTimerCallback()
void newState(QList< State > &states, const char *token, const char *lexem, bool pre)
Combined button and popup list for selecting options.
EGLOutputLayerEXT EGLint EGLAttrib value
[5]
#define Q_DECLARE_LOGGING_CATEGORY(name)
GLint GLsizei GLsizei height
GLuint GLsizei const GLchar * message
static qreal position(const QQuickItem *item, QQuickAnchors::Anchor anchorLine)
QUrl url("example.com")
[constructor-url-reference]