Enumeration

SCNBufferFrequency

Options for how often SceneKit should execute the binding handler you provide with the handleBinding(ofBufferNamed:frequency:handler:) method.

Declaration

enum SCNBufferFrequency : Int

Topics

Constants

case perFrame

Execute the binding handler once for each frame to be rendered using the shader.

case perNode

Execute the binding handler once for each frame, for each node to be rendered using the shader.

case perShadable

Execute the binding handler once for each frame, for each node, for each material or geometry to be rendered using the shader.

See Also

Providing Input for Metal Shaders

func handleBinding(ofBufferNamed: String, frequency: SCNBufferFrequency, handler: SCNBufferBindingBlock)

Registers a block for SceneKit to call at render time for binding a Metal buffer to the shader program.

typealias SCNBufferBindingBlock

A block SceneKit calls at render time for working with buffers in a Metal shader, used by the handleBinding(ofBufferNamed:frequency:handler:) method.