MENU
Statements
The syntaxes for the various statements in WebGL Shading Language share some similarities with the C syntaxes.
| Function Call | returnType functionName([type0 arg0][, type1 arg1]......){...} |
| Iteration | for(...;...;...){...}; while (...){...}; do {...}while(...); |
| Selection | if (...){...} if (...){...}else{...} |
| Jump | break, continue, return, discard // used in the fragment shader to skip the current fragment operation |
| Entry | void main(...){...} |