GLSL
GLSL (OpenGL Shading Language) is the shader language for OpenGL and WebGL: small programs that run on the GPU to compute colors, lighting and visual effects per pixel and per vertex. Essential in 3D graphics and games.
- Creado por OpenGL ARB
- Año 2004
- Paradigma: Shaders · parallel (GPU)
- Extensiones: .glsl, .vert, .frag
Para qué se usa
- 3D graphics
- Visual effects
- Games and WebGL
A favor
- Runs on the GPU
- Powerful visual effects
- Standard in OpenGL/WebGL
En contra
- Shaders only
- Hard to debug
- Parallel mindset
Ecosistema
- OpenGL
- WebGL
- Shadertoy
- GLSL Sandbox
Ejemplo
void main() {
gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0);
}