[Mesa-dev] [PATCH] mesa: propogate FragDepthLayout to gl_program

Chia-I Wu olvaffe at gmail.com
Mon Feb 17 20:25:06 PST 2014


From: Chia-I Wu <olv at lunarg.com>

The information was lost during linking, causing the layout to be treated as
FRAG_DEPTH_LAYOUT_NONE.

Signed-off-by: Chia-I Wu <olv at lunarg.com>
---
 src/mesa/main/shaderapi.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
index 44b4c3a..be7b27b 100644
--- a/src/mesa/main/shaderapi.c
+++ b/src/mesa/main/shaderapi.c
@@ -1865,6 +1865,11 @@ _mesa_copy_linked_program_data(gl_shader_stage type,
       dst_gp->UsesEndPrimitive = src->Geom.UsesEndPrimitive;
    }
       break;
+   case MESA_SHADER_FRAGMENT: {
+      struct gl_fragment_program *dst_fp = (struct gl_fragment_program *) dst;
+      dst_fp->FragDepthLayout = src->FragDepthLayout;
+   }
+      break;
    case MESA_SHADER_COMPUTE: {
       struct gl_compute_program *dst_cp = (struct gl_compute_program *) dst;
       int i;
-- 
1.8.3.1



More information about the mesa-dev mailing list