From bc10714dcfd2c2f043d5c8b5fd2a84a001df5a02 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Tue, 19 Nov 2019 20:32:01 -0300 Subject: gl_shader_gen: Apply default value to gl_Position Nvidia has sane default output values for varyings, but the other vendors don't apply these. To properly emulate this we would have to analyze the shader header. For the time being, apply the same default Nvidia applies so we get the same behaviour on non-Nvidia drivers. --- src/video_core/renderer_opengl/gl_shader_gen.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/video_core/renderer_opengl') diff --git a/src/video_core/renderer_opengl/gl_shader_gen.cpp b/src/video_core/renderer_opengl/gl_shader_gen.cpp index af17216bd..a63c1a6b8 100644 --- a/src/video_core/renderer_opengl/gl_shader_gen.cpp +++ b/src/video_core/renderer_opengl/gl_shader_gen.cpp @@ -32,6 +32,7 @@ layout (std140, binding = EMULATION_UBO_BINDING) uniform vs_config { out += R"( void main() { + gl_Position = vec4(0.0f, 0.0f, 0.0f, 1.0f); execute_vertex(); )"; if (ir_b) { -- cgit v1.2.3