diff options
Diffstat (limited to 'src/core/compositor/native_skia_output_device_metal.h')
-rw-r--r-- | src/core/compositor/native_skia_output_device_metal.h | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/core/compositor/native_skia_output_device_metal.h b/src/core/compositor/native_skia_output_device_metal.h new file mode 100644 index 000000000..8e8d0fab8 --- /dev/null +++ b/src/core/compositor/native_skia_output_device_metal.h @@ -0,0 +1,31 @@ +// Copyright (C) 2024 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +#ifndef NATIVE_SKIA_OUTPUT_DEVICE_METAL_H +#define NATIVE_SKIA_OUTPUT_DEVICE_METAL_H + +#include "native_skia_output_device.h" + +namespace QtWebEngineCore { + +class NativeSkiaOutputDeviceMetal final : public NativeSkiaOutputDevice +{ +public: + NativeSkiaOutputDeviceMetal( + scoped_refptr<gpu::SharedContextState> contextState, bool requiresAlpha, + gpu::MemoryTracker *memoryTracker, viz::SkiaOutputSurfaceDependency *dependency, + gpu::SharedImageFactory *shared_image_factory, + gpu::SharedImageRepresentationFactory *shared_image_representation_factory, + DidSwapBufferCompleteCallback didSwapBufferCompleteCallback); + ~NativeSkiaOutputDeviceMetal() override; + + // Overridden from Compositor: + QSGTexture *texture(QQuickWindow *win, uint32_t textureOptions) override; + +private: + void *m_currentMetalTexture = nullptr; +}; + +} // namespace QtWebEngineCore + +#endif // NATIVE_SKIA_OUTPUT_DEVICE_METAL_H |