mirror of
https://github.com/yuzu-mirror/yuzu.git
synced 2024-11-08 04:39:59 +00:00
gl_rasterizer: Allow rendering without fragment shader
Rendering without a fragment shader is usually used in depth-only passes.
This commit is contained in:
parent
5619d24377
commit
5b989f189f
2 changed files with 7 additions and 0 deletions
|
@ -271,6 +271,9 @@ void RasterizerOpenGL::SetupShaders(GLenum primitive_mode) {
|
||||||
case Maxwell::ShaderProgram::Geometry:
|
case Maxwell::ShaderProgram::Geometry:
|
||||||
shader_program_manager->UseTrivialGeometryShader();
|
shader_program_manager->UseTrivialGeometryShader();
|
||||||
break;
|
break;
|
||||||
|
case Maxwell::ShaderProgram::Fragment:
|
||||||
|
shader_program_manager->UseTrivialFragmentShader();
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,10 @@ public:
|
||||||
current_state.geometry_shader = 0;
|
current_state.geometry_shader = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void UseTrivialFragmentShader() {
|
||||||
|
current_state.fragment_shader = 0;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
struct PipelineState {
|
struct PipelineState {
|
||||||
bool operator==(const PipelineState& rhs) const {
|
bool operator==(const PipelineState& rhs) const {
|
||||||
|
|
Loading…
Reference in a new issue