Shader file formats
Shaders are small programs that run on the graphics card to place, light and colour what appears on screen. They are written in languages such as GLSL and HLSL and often shipped in a compiled form.
Formats
.CSO
Compiled Direct3D shader objectCompiled HLSL shaders for Direct3D: DXBC or DXIL in a container of chunks.
.GLSL
OpenGL Shading Language sourceC-like shader source for OpenGL, WebGL and Vulkan.
.HLSL
High-Level Shader Language sourceMicrosoft’s C-like shader source for Direct3D, also compiled for Vulkan.
.METAL
Metal Shading Language sourceApple’s C++-based shader source for Metal on macOS and iOS.
.SPV
SPIR-V shader moduleCompiled shaders for Vulkan and OpenGL, as a stream of 32-bit words.
.WGSL
WebGPU Shading Language sourceShader source for WebGPU in browsers and native WebGPU libraries.