Specifies a block to be called before rendering using programs with the specified GLSL uniform variable or attribute name.
- iOS 8.0+
- macOS 10.10+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 3.0+
A GLSL uniform variable or attribute name used in one of the technique’s shader programs.
A block that SceneKit calls.
This method associates a block for handling setup of an attribute or uniform variable in the shader programs associated with the technique. SceneKit calls your block before any performing any rendering passes that use that symbol. In the block, you can execute any OpenGL commands or other code necessary for preparing your custom shader.
Use this method when you need to update a value in a shader program every time SceneKit renders a frame. To set a value infrequently, or only once, use the
set method instead.
If you associate a block with a symbol using this method, SceneKit ignores values set using the