Instance Method

setFragmentSamplerStates(_:lodMinClamps:lodMaxClamps:range:)

Sets sampler states for the fragment function in a range of indices in the sampler state argument table, specifying clamp values for levels of detail.

Declaration

func setFragmentSamplerStates(_ samplers: [MTLSamplerState?], lodMinClamps: [Float], lodMaxClamps: [Float], range: Range<Int>)

Parameters

samplers

An array of sampler states to set in the argument table.

lodMinClamps

An array of minimum levels of detail corresponding to the samplers array used when sampling textures.

lodMaxClamps

An array of maximum levels of detail corresponding to the samplers array used when sampling textures.

range

A range of indices in the sampler argument table.

See Also

Specifying Arguments for a Fragment Function

func setFragmentBuffer(MTLBuffer?, offset: Int, index: Int)

Sets a buffer for the fragment function.

Required.

func setFragmentBuffers([MTLBuffer?], offsets: [Int], range: Range<Int>)

Sets an array of buffers for the fragment function in a range of indices in the buffer argument table.

func setFragmentBufferOffset(Int, index: Int)

Sets where the data begins in a buffer already bound to the fragment shader.

Required.

func setFragmentBytes(UnsafeRawPointer, length: Int, index: Int)

Sets a block of data for the fragment shader.

Required.

func setFragmentSamplerState(MTLSamplerState?, index: Int)

Sets a sampler state for the fragment function at an index in the sampler state argument table.

Required.

func setFragmentSamplerState(MTLSamplerState?, lodMinClamp: Float, lodMaxClamp: Float, index: Int)

Sets a sampler state for the fragment function at an index in the sampler state argument table, specifying clamp values for the minimum and maximum level of detail.

Required.

func setFragmentSamplerStates([MTLSamplerState?], range: Range<Int>)

Sets an array of sampler states for the fragment shader function in a range of indices in the sampler state argument table.

func setFragmentTexture(MTLTexture?, index: Int)

Sets a texture for the fragment function at an index in the texture argument table.

Required.

func setFragmentTextures([MTLTexture?], range: Range<Int>)

Sets an array of textures for the fragment function in a range of indices in the texture argument table.