File indexing completed on 2024-04-28 03:55:59
0001 /* 0002 * SPDX-FileCopyrightText: 2020 Arjen Hiemstra <ahiemstra@heimr.nl> 0003 * 0004 * SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include <QSGTexture> 0010 0011 #include "shadowedborderrectanglematerial.h" 0012 0013 class ShadowedBorderTextureMaterial : public ShadowedBorderRectangleMaterial 0014 { 0015 public: 0016 ShadowedBorderTextureMaterial(); 0017 0018 QSGMaterialShader *createShader(QSGRendererInterface::RenderMode) const override; 0019 QSGMaterialType *type() const override; 0020 int compare(const QSGMaterial *other) const override; 0021 0022 QSGTexture *textureSource = nullptr; 0023 0024 static QSGMaterialType staticType; 0025 }; 0026 0027 class ShadowedBorderTextureShader : public ShadowedBorderRectangleShader 0028 { 0029 public: 0030 ShadowedBorderTextureShader(ShadowedRectangleMaterial::ShaderType shaderType); 0031 0032 void 0033 updateSampledImage(QSGMaterialShader::RenderState &state, int binding, QSGTexture **texture, QSGMaterial *newMaterial, QSGMaterial *oldMaterial) override; 0034 };