summaryrefslogtreecommitdiff
path: root/Source/Core/VideoBackends/OGL/TextureCache.cpp
diff options
context:
space:
mode:
authorMat M <mathew1800@gmail.com>2016-12-23 04:33:42 -0500
committerGitHub <noreply@github.com>2016-12-23 04:33:42 -0500
commit9160be50dbfa31073eda0148378786f69b219805 (patch)
tree579bca3b98e8dd47ec3b18911504a669a2853cf9 /Source/Core/VideoBackends/OGL/TextureCache.cpp
parentf2322bee90c1bd973a6cc4e99d4df78c7d2d0027 (diff)
parent58a53951735aba77899ea8f8910a6b68dc52449a (diff)
Merge pull request #4224 from lioncash/tcache
TextureCacheBase: Eliminate static state
Diffstat (limited to 'Source/Core/VideoBackends/OGL/TextureCache.cpp')
-rw-r--r--Source/Core/VideoBackends/OGL/TextureCache.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/Core/VideoBackends/OGL/TextureCache.cpp b/Source/Core/VideoBackends/OGL/TextureCache.cpp
index 50c729d45e..20c3f488cc 100644
--- a/Source/Core/VideoBackends/OGL/TextureCache.cpp
+++ b/Source/Core/VideoBackends/OGL/TextureCache.cpp
@@ -178,8 +178,8 @@ void TextureCache::TCacheEntry::CopyRectangleFromTexture(const TCacheEntryBase*
g_renderer->RestoreAPIState();
}
-void TextureCache::TCacheEntry::Load(unsigned int width, unsigned int height,
- unsigned int expanded_width, unsigned int level)
+void TextureCache::TCacheEntry::Load(const u8* buffer, u32 width, u32 height, u32 expanded_width,
+ u32 level)
{
if (level >= config.levels)
PanicAlert("Texture only has %d levels, can't update level %d", config.levels, level);
@@ -196,7 +196,7 @@ void TextureCache::TCacheEntry::Load(unsigned int width, unsigned int height,
glPixelStorei(GL_UNPACK_ROW_LENGTH, expanded_width);
glTexImage3D(GL_TEXTURE_2D_ARRAY, level, GL_RGBA, width, height, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE,
- temp);
+ buffer);
if (expanded_width != width)
glPixelStorei(GL_UNPACK_ROW_LENGTH, 0);