diff options
author | Alyssa Rosenzweig <[email protected]> | 2019-12-20 12:38:24 -0500 |
---|---|---|
committer | Alyssa Rosenzweig <[email protected]> | 2019-12-24 23:46:22 +0000 |
commit | 64b2fe96268a520fe595a7ac54ae5e964f1807b1 (patch) | |
tree | c015744f8065cbf36716c92ba07f702b2bba69ea /src/panfrost/midgard | |
parent | 72e5749a635ca864c99a149df42685eb1cb48620 (diff) |
pan/midgard: Expand swizzle for texelFetch
We zero the extra components anyway. Fixes
dEQP-GLES3.functional.shaders.texture_functions.texelfetch.sampler2d_fixed_fragment
Signed-off-by: Alyssa Rosenzweig <[email protected]>
Diffstat (limited to 'src/panfrost/midgard')
-rw-r--r-- | src/panfrost/midgard/midgard_compile.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/panfrost/midgard/midgard_compile.c b/src/panfrost/midgard/midgard_compile.c index 8d457de950e..f462100a280 100644 --- a/src/panfrost/midgard/midgard_compile.c +++ b/src/panfrost/midgard/midgard_compile.c @@ -1813,6 +1813,12 @@ emit_texop_native(compiler_context *ctx, nir_tex_instr *instr, unreachable("Invalid texture 2D components"); } + if (midgard_texop == TEXTURE_OP_TEXEL_FETCH) { + /* We zeroed */ + ins.swizzle[1][2] = COMPONENT_Z; + ins.swizzle[1][3] = COMPONENT_W; + } + break; } |