sampler SamplerName[Array_Index] [= Initializers];
where:
sampler | The sampler keyword must appear here. |
SamplerName[Array_Index] | An ASCII string that uniquely identifies the name of a variable within a shader. Each variable can be defined as a single variable or optionally as an array of variables. Array_Index is the optional array size and is specified as a positive integer greater than or equal to 1. |
Initializers | Initializers specify default sampler state. Initializers are optional. If initializers are used, they must appear within a statement block (delimited by {}) with the sampler_state keyword as shown here:
= sampler_state { ...; // sampling state ...; // sampling state }; |
This sampler is initialized with linear filtering.
sampler s = sampler_state { texture = NULL; mipfilter = LINEAR; };