blob: 1c71310448148ea2268f56931f0e35387b28fdee (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
// Copyright (C) 2019 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
#ifndef QWASMOFFSCREENSURFACE_H
#define QWASMOFFSCREENSURFACE_H
#include <qpa/qplatformoffscreensurface.h>
#include <emscripten/val.h>
#include <string>
QT_BEGIN_NAMESPACE
class QOffscreenSurface;
class QWasmOffscreenSurface final : public QPlatformOffscreenSurface
{
public:
explicit QWasmOffscreenSurface(QOffscreenSurface *offscreenSurface);
~QWasmOffscreenSurface() final;
const std::string &id() const { return m_specialTargetId; }
bool isValid() const override;
private:
std::string m_specialTargetId;
emscripten::val m_offscreenCanvas;
};
QT_END_NAMESPACE
#endif
|