summaryrefslogtreecommitdiffstats
path: root/src/compiler/nir/nir.h
diff options
context:
space:
mode:
authorKristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>2016-05-01 21:13:37 -0700
committerKristian Høgsberg Kristensen <krh@bitplanet.net>2016-05-24 10:14:56 -0700
commita41b57679fd659dda1b6df3286b34c13cac7811a (patch)
treef69a1b63d3dfb628f203527852fc4257fd4a0d0e /src/compiler/nir/nir.h
parent50c24c3ff34882864b74862abdbaa5d7dcd8730d (diff)
downloadexternal_mesa3d-a41b57679fd659dda1b6df3286b34c13cac7811a.zip
external_mesa3d-a41b57679fd659dda1b6df3286b34c13cac7811a.tar.gz
external_mesa3d-a41b57679fd659dda1b6df3286b34c13cac7811a.tar.bz2
nir: Add a lowering pass for YUV textures
This lowers sampling from YUV textures to 1) one or more texture instructions to sample each plane and 2) color space conversion to RGB. Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Diffstat (limited to 'src/compiler/nir/nir.h')
-rw-r--r--src/compiler/nir/nir.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/compiler/nir/nir.h b/src/compiler/nir/nir.h
index ace6fbb..96246f6 100644
--- a/src/compiler/nir/nir.h
+++ b/src/compiler/nir/nir.h
@@ -2346,6 +2346,13 @@ typedef struct nir_lower_tex_options {
bool lower_rect;
/**
+ * If true, convert yuv to rgb.
+ */
+ unsigned lower_y_uv_external;
+ unsigned lower_y_u_v_external;
+ unsigned lower_yx_xuxv_external;
+
+ /**
* To emulate certain texture wrap modes, this can be used
* to saturate the specified tex coord to [0.0, 1.0]. The
* bits are according to sampler #, ie. if, for example: