Select
In GLSL, you have both if statements and the ternary operator in order to be able to evaluate which of two expressions should be used. This can be achieved using the select
function which works like a ternary operator.
The condition must be of type BooleanNode
and the values need to be of the same type.
Last updated