TextureSampler

constructor()

Creates a TextureSampler with the default parameters: NEAREST filtering, CLAMP_TO_EDGE on all axes, anisotropy 1, no comparison.


constructor(minMag: TextureSampler.MagFilter, str: TextureSampler.WrapMode = WrapMode.CLAMP_TO_EDGE)

Creates a TextureSampler with the same minification and magnification filter and one wrap mode for all axes.

Parameters

minMag

Filtering for both minification and magnification.

str

Wrapping mode applied to all three axes (S, T, R).


constructor(min: TextureSampler.MinFilter, mag: TextureSampler.MagFilter, str: TextureSampler.WrapMode = WrapMode.CLAMP_TO_EDGE)

Creates a TextureSampler with separate minification and magnification filters, and a wrap mode applied to all axes.

Parameters

min

Minification filter.

mag

Magnification filter.

str

Wrapping mode applied to all three axes (S, T, R).


Creates a TextureSampler with separate filters and wrap modes for each axis.

Parameters

min

Minification filter.

mag

Magnification filter.

s

Wrap mode for the S (horizontal) texture coordinate.

t

Wrap mode for the T (vertical) texture coordinate.

r

Wrap mode for the R (depth) texture coordinate.


constructor(mode: TextureSampler.CompareMode, func: TextureSampler.CompareFunc = CompareFunc.LE)

Creates a TextureSampler with default filtering and wrapping, and the given comparison mode.

Parameters

mode

Compare mode to use.

func

Comparison function.