aboutsummaryrefslogtreecommitdiffstats
path: root/src/compiler/shader_info.h
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2017-10-26 15:19:25 -0700
committerKenneth Graunke <[email protected]>2017-10-29 20:52:20 -0700
commit86c68bb88618c5138a22bbbcfe6137d29f9f5f67 (patch)
treed26686251d0fc3bb27192fa74ec20ad413fb9314 /src/compiler/shader_info.h
parentf970e4d481bb459822e8f3b6a9599e661c5ceb0d (diff)
nir: Make nir_gather_info collect a uses_fddx_fddy flag.
i965 turns fddx/fddy into their coarse/fine variants based on the ctx->Hint.FragmentShaderDerivative setting. It needs to know whether this can impact a shader in order to better guess NOS settings. Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/compiler/shader_info.h')
-rw-r--r--src/compiler/shader_info.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/compiler/shader_info.h b/src/compiler/shader_info.h
index cd044d86094..5f14ad19df7 100644
--- a/src/compiler/shader_info.h
+++ b/src/compiler/shader_info.h
@@ -73,6 +73,13 @@ typedef struct shader_info {
/** Bitfield of which textures are used by texelFetch() */
uint32_t textures_used_by_txf;
+ /**
+ * True if this shader uses the fddx/fddy opcodes.
+ *
+ * Note that this does not include the "fine" and "coarse" variants.
+ */
+ bool uses_fddx_fddy;
+
/* The size of the gl_ClipDistance[] array, if declared. */
unsigned clip_distance_array_size;