remotion-dev/remotion · error
LUT shader compile failed
Error message
LUT shader compile failed: ${log ?? '(no log)'} What it means
The GLSL shader source shipped with the LUT effect failed to compile. The thrown message includes the driver's shader info log (or '(no log)' if none was produced). Since the bundled LUT shaders are static, this almost always indicates a WebGL/driver problem rather than user code.
Solutions
- Read the log portion of the error message — it names the exact GLSL error and line.
- Update GPU drivers / enable hardware acceleration (chrome://settings/system) and retry.
- Try another browser (Chrome/Firefox/Safari latest) to isolate a driver-specific GLSL bug.
- If the log indicates resource limits, reduce context count or upgrade the environment; report a Remotion bug with the full log if the bundled shader itself is rejected.
Defensive patterns
Strategy: try-catch
Validate before calling
const gl = canvas.getContext('webgl2');
if (!gl) throw new Error('WebGL2 unavailable');
// no reliable pre-check for GLSL compilation exists; surface the info log when it fails Try / catch
try {
applyLutEffect(canvas);
} catch (e) {
if (e instanceof Error && e.message.startsWith('LUT shader compile failed:')) {
console.error('GPU/driver rejected the LUT shader:', e.message);
// fall back to rendering without the LUT or switch browser/driver
} else throw e;
} Prevention
- Keep GPU drivers current and hardware acceleration on
- Test rendering in the latest Chrome/Firefox/Safari before deploying
- Capture and log the full shader info log for bug reports
- Avoid exotic software-rendering environments (minimal VMs without GPU) for video rendering
When it happens
Trigger: setupLut -> createProgram -> compileShader runs and gl.getShaderParameter(shader, COMPILE_STATUS) is false. Happens on browsers/drivers with broken or limited GLSL ES 3.0 support, or when the GLSL ES 3.00 shader (#version 300 es) is rejected by old software renderers.
Common situations: Outdated GPU drivers or blocked hardware acceleration forcing ANGLE/SwiftShader quirks; old mobile WebViews with incomplete WebGL2 GLSL support; virtual machines without proper GPU passthrough.
Related errors
- Linear gradient program link failed
- Linear gradient shader compile failed
- Linear progressive blur program link failed
- Linear progressive blur shader compile failed
- Lines shader compile failed
AI-assisted analysis of remotion-dev/remotion@46a3a6bf13 (2026-09-18).
Data as JSON: /api/errors/7f3309cd50bdc60c.
Report an issue: GitHub.
Appendix: source
Thrown at packages/effects/src/lut/lut-runtime.ts:39
cachedContent: string | null;
};
const compileShader = (
gl: WebGL2RenderingContext,
type: number,
source: string,
): WebGLShader => {
const shader = gl.createShader(type);
if (!shader) {
throw new Error('Failed to create LUT shader');
}
gl.shaderSource(shader, source);
gl.compileShader(shader);
if (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {
const log = gl.getShaderInfoLog(shader);
gl.deleteShader(shader);
throw new Error(`LUT shader compile failed: ${log ?? '(no log)'}`);
}
return shader;
};
const createProgram = (gl: WebGL2RenderingContext): WebGLProgram => {
const vertexShader = compileShader(gl, gl.VERTEX_SHADER, LUT_VERTEX_SHADER);
const fragmentShader = compileShader(
gl,
gl.FRAGMENT_SHADER,
LUT_FRAGMENT_SHADER,
);
const program = gl.createProgram();
if (!program) {
throw new Error('Failed to create LUT shader program');
}
gl.attachShader(program, vertexShader);View on GitHub (pinned to 46a3a6bf13)