From 8aeff9cf8e84c27ab83cea8df1a94ce8082efc78 Mon Sep 17 00:00:00 2001 From: bunnei Date: Thu, 12 Jul 2018 22:57:57 -0400 Subject: gl_rasterizer: Fix check for if a shader stage is enabled. --- src/video_core/engines/maxwell_3d.h | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/video_core/engines/maxwell_3d.h') diff --git a/src/video_core/engines/maxwell_3d.h b/src/video_core/engines/maxwell_3d.h index 5a7cf0107..6f0170ff7 100644 --- a/src/video_core/engines/maxwell_3d.h +++ b/src/video_core/engines/maxwell_3d.h @@ -379,6 +379,14 @@ public: } }; + bool IsShaderConfigEnabled(size_t index) const { + // The VertexB is always enabled. + if (index == static_cast(Regs::ShaderProgram::VertexB)) { + return true; + } + return shader_config[index].enable != 0; + } + union { struct { INSERT_PADDING_WORDS(0x45); @@ -780,9 +788,6 @@ public: /// Returns the texture information for a specific texture in a specific shader stage. Texture::FullTextureInfo GetStageTexture(Regs::ShaderStage stage, size_t offset) const; - /// Returns whether the specified shader stage is enabled or not. - bool IsShaderStageEnabled(Regs::ShaderStage stage) const; - private: std::unordered_map> uploaded_macros; -- cgit v1.2.3