(25932126b1af4b323e476adb2b8b0edddd466804)
#include <QDebug>
#include <QUrl>
#include <QPoint>
#include <QRect>
#include <QMediaPlayer>
#include <QVideoFrame>
#include <QFile>
#include <QBuffer>
#include <QMimeDatabase>
#include <QGuiApplication>
#include <QOpenGLContext>
#include <QtGui/rhi/qrhi_platform.h>
#include <qpa/qplatformwindow_p.h>
#include <GLES2/gl2.h>
#include "qwasmvideooutput_p.h"
#include <qvideosink.h>
#include <private/qplatformvideosink_p.h>
#include <private/qmemoryvideobuffer_p.h>
#include <private/qvideotexturehelper_p.h>
#include <private/qvideoframe_p.h>
#include <private/qstdweb_p.h>
#include <QTimer>
#include <emscripten/bind.h>
#include <emscripten/val.h>
#include "moc_qwasmvideooutput_p.cpp"
Go to the source code of this file.
|
| | EM_JS (void, em_texImage2DFromVideo,(EM_VAL canvasHandle, const char *videoId, int *pW, int *pH), { var canvas=Emval.toValue(canvasHandle);var gl=canvas.getContext('webgl2')||canvas.getContext('webgl');var video=document.getElementById(UTF8ToString(videoId));var frame=new VideoFrame(video);HEAP32[pW > > 2]=frame.displayWidth;HEAP32[pH > > 2]=frame.displayHeight;gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, frame);frame.close();}) |
| static bool | checkForVideoFrame () |
◆ checkForVideoFrame()
| bool checkForVideoFrame |
( |
| ) |
|
|
static |
◆ EM_JS()
| EM_JS |
( |
void | , |
|
|
em_texImage2DFromVideo | , |
|
|
(EM_VAL canvasHandle, const char *videoId, int *pW, int *pH) | , |
|
|
{ var canvas=Emval.toValue(canvasHandle);var gl=canvas.getContext('webgl2')||canvas.getContext('webgl');var video=document.getElementById(UTF8ToString(videoId));var frame=new VideoFrame(video);HEAP32[pW > > 2]=frame.displayWidth;HEAP32[pH > > 2]=frame.displayHeight;gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, frame);frame.close();} | ) |