Skip to content

Commit

Permalink
shader: Fix shadow_texture_orthographic not being set correctly. (#6937)
Browse files Browse the repository at this point in the history
  • Loading branch information
Steveice10 authored Aug 31, 2023
1 parent 1159e4d commit 5ad58e0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions src/video_core/renderer_opengl/gl_shader_gen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -256,9 +256,7 @@ PicaFSConfig PicaFSConfig::BuildFromRegs(const Pica::Regs& regs, bool has_blend_

state.shadow_rendering = regs.framebuffer.output_merger.fragment_operation_mode ==
FramebufferRegs::FragmentOperationMode::Shadow;
if (state.shadow_rendering) {
state.shadow_texture_orthographic = regs.texturing.shadow.orthographic != 0;
}
state.shadow_texture_orthographic = regs.texturing.shadow.orthographic != 0;

state.use_custom_normal_map = use_normal;

Expand Down
4 changes: 1 addition & 3 deletions src/video_core/renderer_vulkan/vk_shader_gen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -235,9 +235,7 @@ PicaFSConfig::PicaFSConfig(const Pica::Regs& regs, const Instance& instance) {

state.shadow_rendering.Assign(regs.framebuffer.output_merger.fragment_operation_mode ==
FramebufferRegs::FragmentOperationMode::Shadow);
if (state.shadow_rendering) {
state.shadow_texture_orthographic.Assign(regs.texturing.shadow.orthographic != 0);
}
state.shadow_texture_orthographic.Assign(regs.texturing.shadow.orthographic != 0);
}

void PicaShaderConfigCommon::Init(const Pica::RasterizerRegs& rasterizer,
Expand Down

0 comments on commit 5ad58e0

Please sign in to comment.