summaryrefslogtreecommitdiff
path: root/src/video_core
diff options
context:
space:
mode:
authorGravatar unknown2019-02-10 10:28:04 +0100
committerGravatar FreddyFunk2019-03-29 18:22:08 +0100
commitb4857e326fdf4c980c88ca399e7d12f99253777e (patch)
tree5e90dbe3f86317723ee15306cdf1de38d6405790 /src/video_core
parentgl_shader_disk_cache: Fixup clang format (diff)
downloadyuzu-b4857e326fdf4c980c88ca399e7d12f99253777e.tar.gz
yuzu-b4857e326fdf4c980c88ca399e7d12f99253777e.tar.xz
yuzu-b4857e326fdf4c980c88ca399e7d12f99253777e.zip
common/zstd_compression: simplify decompression interface
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/renderer_opengl/gl_shader_disk_cache.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp b/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp
index ec32602ad..8a43eb157 100644
--- a/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp
@@ -259,7 +259,7 @@ ShaderDiskCacheOpenGL::LoadPrecompiledFile(FileUtil::IOFile& file) {
259 return {}; 259 return {};
260 } 260 }
261 261
262 dump.binary = Common::Compression::DecompressDataZSTD(compressed_binary, binary_length); 262 dump.binary = Common::Compression::DecompressDataZSTD(compressed_binary);
263 if (dump.binary.empty()) { 263 if (dump.binary.empty()) {
264 return {}; 264 return {};
265 } 265 }
@@ -288,8 +288,7 @@ std::optional<ShaderDiskCacheDecompiled> ShaderDiskCacheOpenGL::LoadDecompiledEn
288 return {}; 288 return {};
289 } 289 }
290 290
291 const std::vector<u8> code = 291 const std::vector<u8> code = Common::Compression::DecompressDataZSTD(compressed_code);
292 Common::Compression::DecompressDataZSTD(compressed_code, code_size);
293 if (code.empty()) { 292 if (code.empty()) {
294 return {}; 293 return {};
295 } 294 }