diff options
author | Miikka Heikkinen <miikka.heikkinen@qt.io> | 2020-02-20 17:03:03 +0200 |
---|---|---|
committer | Miikka Heikkinen <miikka.heikkinen@qt.io> | 2020-02-25 09:45:24 +0200 |
commit | 3f1cbceae33d346f939b76a18b91c45abe038051 (patch) | |
tree | c1567118b8dd779470d9774c270bf364cfdd3f33 /src/api/studio3d/q3dspresentation.h | |
parent | 9db175350be8223f947a2c0436f59586a86e921b (diff) |
Shader caching improvements
Added shader cache load error generation to some cases where it was
missing.
Properly pass the error to surface viewer.
If there was a cache load error, allow exporting the generated cache.
Added overloads to generate shader cache with specified compression
level.
Change-Id: I06d56114918ada23d46474e9466f6031ad8037e2
Fixes: QT3DS-4071
Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
Reviewed-by: Janne Kangas <janne.kangas@qt.io>
Reviewed-by: Antti Määttä <antti.maatta@qt.io>
Diffstat (limited to 'src/api/studio3d/q3dspresentation.h')
-rw-r--r-- | src/api/studio3d/q3dspresentation.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/api/studio3d/q3dspresentation.h b/src/api/studio3d/q3dspresentation.h index 44bcad5..6d25a74 100644 --- a/src/api/studio3d/q3dspresentation.h +++ b/src/api/studio3d/q3dspresentation.h @@ -97,6 +97,10 @@ public: bool binaryShaders); Q_REVISION(1) Q_INVOKABLE void exportShaderCache(bool binaryShaders); void exportShaderCache(QByteArray &cacheData, bool binaryShaders); + Q_REVISION(2) Q_INVOKABLE void exportShaderCache(const QUrl &shaderCacheFile, + bool binaryShaders, int compressionLevel); + Q_REVISION(2) Q_INVOKABLE void exportShaderCache(bool binaryShaders, int compressionLevel); + void exportShaderCache(QByteArray &cacheData, bool binaryShaders, int compressionLevel); void setShaderCacheData(const QByteArray &shaderCache); QUrl shaderCacheFile() const; |