aboutsummaryrefslogtreecommitdiff
path: root/src/video_core/texture_cache/surface_base.cpp
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2019-04-25 13:41:57 -0300
committerReinUsesLisp <reinuseslisp@airmail.cc>2019-06-20 21:36:11 -0300
commit05f039e9fb8448962a7a6d0e4db4fcf98b6076cf (patch)
treec508c35c4bc1bf436a22888cd6c150dfbe07edc8 /src/video_core/texture_cache/surface_base.cpp
parentdfe6cbac91a3dce8ccea98fc19f06c162ed58cee (diff)
texture_cache: Remove execution context copies from the texture cache
This is done to simplify the OpenGL implementation, it is needed for Vulkan.
Diffstat (limited to 'src/video_core/texture_cache/surface_base.cpp')
-rw-r--r--src/video_core/texture_cache/surface_base.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/video_core/texture_cache/surface_base.cpp b/src/video_core/texture_cache/surface_base.cpp
index 8680485b4c..d0779b5027 100644
--- a/src/video_core/texture_cache/surface_base.cpp
+++ b/src/video_core/texture_cache/surface_base.cpp
@@ -53,8 +53,8 @@ void SurfaceBaseImpl::LoadBuffer() {
ASSERT_MSG(params.GetBlockWidth() == 1, "Block width is defined as {} on texture target {}",
params.GetBlockWidth(), static_cast<u32>(params.GetTarget()));
for (u32 level = 0; level < params.GetNumLevels(); ++level) {
- u8* const buffer{GetStagingBufferLevelData(level)};
- SwizzleFunc(MortonSwizzleMode::MortonToLinear, host_ptr, params, buffer, level);
+ SwizzleFunc(MortonSwizzleMode::MortonToLinear, host_ptr, params,
+ GetStagingBufferLevelData(level), level);
}
} else {
ASSERT_MSG(params.GetNumLevels() == 1, "Linear mipmap loading is not implemented");
@@ -89,8 +89,8 @@ void SurfaceBaseImpl::FlushBuffer() {
ASSERT_MSG(params.GetBlockWidth() == 1, "Block width is defined as {}",
params.GetBlockWidth());
for (u32 level = 0; level < params.GetNumLevels(); ++level) {
- u8* const buffer = GetStagingBufferLevelData(level);
- SwizzleFunc(MortonSwizzleMode::LinearToMorton, GetHostPtr(), params, buffer, level);
+ SwizzleFunc(MortonSwizzleMode::LinearToMorton, GetHostPtr(), params,
+ GetStagingBufferLevelData(level), level);
}
} else {
UNIMPLEMENTED();