diff options
Diffstat (limited to 'src/render/texture/texture_p.h')
-rw-r--r-- | src/render/texture/texture_p.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/render/texture/texture_p.h b/src/render/texture/texture_p.h index 86c49f695..c60e90181 100644 --- a/src/render/texture/texture_p.h +++ b/src/render/texture/texture_p.h @@ -137,10 +137,18 @@ public: DirtyProperties = 0x1, DirtyParameters = 0x2, DirtyImageGenerators = 0x4, - DirtyDataGenerator = 0x8 + DirtyDataGenerator = 0x8, + DirtySharedTextureId = 0x16 }; Q_DECLARE_FLAGS(DirtyFlags, DirtyFlag) + struct TextureUpdateInfo + { + TextureProperties properties; + QVariant handle; + QAbstractTexture::HandleType handleType; + }; + void addDirtyFlag(DirtyFlags flags); DirtyFlags dirtyFlags(); void unsetDirty(); @@ -155,9 +163,10 @@ public: inline const TextureParameters& parameters() const { return m_parameters; } inline const Qt3DCore::QNodeIdVector textureImageIds() const { return m_textureImageIds; } inline const QTextureGeneratorPtr& dataGenerator() const { return m_dataFunctor; } + inline int sharedTextureId() const { return m_sharedTextureId; } void setDataGenerator(const QTextureGeneratorPtr &generator); - void updatePropertiesAndNotify(const TextureProperties &propreties); + void updatePropertiesAndNotify(const TextureUpdateInfo &updateInfo); bool isValid(TextureImageManager *manager) const; private: void initializeFromPeer(const Qt3DCore::QNodeCreatedChangeBasePtr &change) final; @@ -165,6 +174,7 @@ private: DirtyFlags m_dirty; TextureProperties m_properties; TextureParameters m_parameters; + int m_sharedTextureId; QTextureGeneratorPtr m_dataFunctor; Qt3DCore::QNodeIdVector m_textureImageIds; |