remotion-dev/remotion · error · Error
Contour lines program link failed: ${log ?? '(no log)'}
Error message
Contour lines program link failed: ${log ?? '(no log)'} What it means
Thrown by linkProgram in contour-lines.ts when gl.getProgramParameter(program, gl.LINK_STATUS) returns false. The vertex and fragment shaders compiled but could not be linked into a working program. The info log from gl.getProgramInfoLog() is included. Since both shaders are library constants, a link failure is a driver/GPU compatibility issue, not a user parameter problem.
Source
Thrown at packages/effects/src/contour-lines.ts:385
};
const linkProgram = (
gl: WebGL2RenderingContext,
vs: WebGLShader,
fs: WebGLShader,
): WebGLProgram => {
const program = gl.createProgram();
if (!program) {
throw new Error('Failed to create WebGL program');
}
gl.attachShader(program, vs);
gl.attachShader(program, fs);
gl.linkProgram(program);
if (!gl.getProgramParameter(program, gl.LINK_STATUS)) {
const log = gl.getProgramInfoLog(program);
gl.deleteProgram(program);
throw new Error(`Contour lines program link failed: ${log ?? '(no log)'}`);
}
return program;
};
const createProgram = (
gl: WebGL2RenderingContext,
vertexSource: string,
fragmentSource: string,
): WebGLProgram => {
const vs = compileShader(gl, gl.VERTEX_SHADER, vertexSource);
const fs = compileShader(gl, gl.FRAGMENT_SHADER, fragmentSource);
const program = linkProgram(gl, vs, fs);
gl.deleteShader(vs);
gl.deleteShader(fs);
return program;
};
View on GitHub (pinned to 78fe4bb3fd)
Solutions
- Update GPU drivers.
- Test on a different GPU or browser to isolate driver-specific linker bugs.
- For headless rendering, use a Chrome build with full WebGL2/SwiftShader support.
- Report the info log to Remotion with GPU/driver details if it reproduces on modern hardware.
Defensive patterns
Strategy: try-catch
Try / catch
try {
contourLines({...})(source, target);
} catch (e) {
if (e instanceof Error && e.message.startsWith('Contour lines program link failed')) {
// driver-specific linker issue — capture info log from message
}
throw e;
} Prevention
- Update GPU drivers.
- Test on different GPU/browser to isolate driver linker bugs.
- Use Chrome with full WebGL2 support for headless rendering.
- Capture the info log from the error message when reporting.
When it happens
Trigger: setupContourLines compiles both shaders, creates a program, attaches the shaders, calls gl.linkProgram(), and LINK_STATUS is false. Internal to the contour-lines WebGL pipeline setup.
Common situations: Vertex/fragment shader interface mismatch on a strict driver (e.g. varying/in-out declarations, precision qualifiers); GPU driver bug in the program linker; incomplete WebGL2 implementation that compiles shaders individually but fails cross-shader validation; running on older mobile GPU drivers.
Related errors
- Contour lines shader compile failed: ${log ?? '(no log)'}
- Shader compile failed: ${log ?? '(no log)'}
- Program link failed: ${log ?? '(no log)'}
- Noise shader compile failed: ${log ?? '(no log)'}
- Paper shader compile failed: ${log ?? '(no log)'}
AI-assisted analysis of remotion-dev/remotion@78fe4bb3fd (2026-08-12).
Data as JSON: /api/errors/6d82c729a1e40484.
Report an issue: GitHub.