Module: wine Branch: master Commit: 96b48191c0625bbbda8b6b3422fb569c1b57a566 URL: http://source.winehq.org/git/wine.git/?a=commit;h=96b48191c0625bbbda8b6b3422...
Author: Matteo Bruni mbruni@codeweavers.com Date: Fri Feb 6 15:25:32 2015 +0100
wined3d: Only copy POSITION0 output semantics into gl_Position.
---
dlls/wined3d/glsl_shader.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c index f3e921c..adb9f13 100644 --- a/dlls/wined3d/glsl_shader.c +++ b/dlls/wined3d/glsl_shader.c @@ -4377,7 +4377,7 @@ static GLuint generate_param_reorder_function(struct wined3d_shader_buffer *buff shader_addline(buffer, "gl_FrontSecondaryColor%s = vs_out[%u]%s;\n", reg_mask, i, reg_mask); } - else if (shader_match_semantic(semantic_name, WINED3D_DECL_USAGE_POSITION)) + else if (shader_match_semantic(semantic_name, WINED3D_DECL_USAGE_POSITION) && !semantic_idx) { shader_addline(buffer, "gl_Position%s = vs_out[%u]%s;\n", reg_mask, i, reg_mask); @@ -4419,9 +4419,10 @@ static GLuint generate_param_reorder_function(struct wined3d_shader_buffer *buff if (!(map & 1)) continue;
semantic_name = output_signature[i].semantic_name; + semantic_idx = output_signature[i].semantic_idx; shader_glsl_write_mask_to_str(output_signature[i].mask, reg_mask);
- if (shader_match_semantic(semantic_name, WINED3D_DECL_USAGE_POSITION)) + if (shader_match_semantic(semantic_name, WINED3D_DECL_USAGE_POSITION) && !semantic_idx) { shader_addline(buffer, "gl_Position%s = vs_out[%u]%s;\n", reg_mask, i, reg_mask);