From 220df45b7dfc3654fe0fb4cb6b6eb65c1bfce8e3 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Wed, 9 Jan 2019 17:42:27 -0300 Subject: [PATCH] gl_state: Remove texture target tracking --- src/video_core/renderer_opengl/gl_rasterizer.cpp | 3 --- src/video_core/renderer_opengl/gl_state.h | 2 -- 2 files changed, 5 deletions(-) diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp index 79d16d1f3..7831bc8cc 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.cpp +++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp @@ -1022,11 +1022,8 @@ void RasterizerOpenGL::SetupTextures(Maxwell::ShaderStage stage, const Shader& s if (surface != nullptr) { unit.texture = entry.IsArray() ? surface->TextureLayer().handle : surface->Texture().handle; - const GLenum target = entry.IsArray() ? surface->TargetLayer() : surface->Target(); surface->UpdateSwizzle(texture.tic.x_source, texture.tic.y_source, texture.tic.z_source, texture.tic.w_source); - unit.texture = handle; - unit.target = target; } else { // Can occur when texture addr is null or its memory is unmapped/invalid unit.texture = 0; diff --git a/src/video_core/renderer_opengl/gl_state.h b/src/video_core/renderer_opengl/gl_state.h index ced602bf6..9e1eda5b1 100644 --- a/src/video_core/renderer_opengl/gl_state.h +++ b/src/video_core/renderer_opengl/gl_state.h @@ -126,7 +126,6 @@ public: struct TextureUnit { GLuint texture; // GL_TEXTURE_BINDING_2D GLuint sampler; // GL_SAMPLER_BINDING - GLenum target; void Unbind() { texture = 0; @@ -135,7 +134,6 @@ public: void Reset() { Unbind(); sampler = 0; - target = GL_TEXTURE_2D; } }; std::array texture_units;