[Mesa-dev] [PATCH 3/6] glsl: Put `sample`-qualified varyings in their own packing classes

Chris Forbes chrisf at ijw.co.nz
Fri Nov 29 00:54:37 PST 2013


Signed-off-by: Chris Forbes <chrisf at ijw.co.nz>
---
 src/glsl/link_varyings.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/glsl/link_varyings.cpp b/src/glsl/link_varyings.cpp
index d2a4fc8..097cee5 100644
--- a/src/glsl/link_varyings.cpp
+++ b/src/glsl/link_varyings.cpp
@@ -887,7 +887,7 @@ varying_matches::compute_packing_class(ir_variable *var)
     *
     * Therefore, the packing class depends only on the interpolation type.
     */
-   unsigned packing_class = var->centroid ? 1 : 0;
+   unsigned packing_class = var->centroid | (var->sample << 1);
    packing_class *= 4;
    packing_class += var->interpolation;
    return packing_class;
-- 
1.8.4.2



More information about the mesa-dev mailing list