- Real-Time 3D Graphics with WebGL 2
- Farhad Ghayour Diego Cantor
- 55字
- 2021-06-10 19:42:54
Uniforms
Uniforms are input variables that are available to both the vertex shader and the fragment shader. Unlike attributes, uniforms are constant during a rendering cycle. For example, the position of a light is often modeled as a uniform. Uniforms are effectively global variables that you set before executing your shader program.