remotion-dev/remotion · error · Error
Failed to create WebGL vertex array
Error message
Failed to create WebGL vertex array
What it means
Thrown by setupLinearProgressiveBlur() when gl.createVertexArray() returns null after the two programs and textures are built. The runtime needs a VAO to bind the fullscreen-quad attributes for both blur passes, so it aborts rather than drawing nothing.
Source
Thrown at packages/effects/src/linear-progressive-blur/linear-progressive-blur-runtime.ts:146
throw createWebGL2ContextError('linear progressive blur effect');
}
gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, true);
const programHorizontal = createProgram(
gl,
LINEAR_PROGRESSIVE_BLUR_VS,
buildLinearProgressiveBlurFs('horizontal'),
);
const programVertical = createProgram(
gl,
LINEAR_PROGRESSIVE_BLUR_VS,
buildLinearProgressiveBlurFs('vertical'),
);
const vao = gl.createVertexArray();
if (!vao) {
throw new Error('Failed to create WebGL vertex array');
}
gl.bindVertexArray(vao);
const data = new Float32Array([
-1, -1, 0, 0, 1, -1, 1, 0, -1, 1, 0, 1, 1, 1, 1, 1,
]);
const vbo = gl.createBuffer();
if (!vbo) {
throw new Error('Failed to create WebGL buffer');
}
gl.bindBuffer(gl.ARRAY_BUFFER, vbo);
gl.bufferData(gl.ARRAY_BUFFER, data, gl.STATIC_DRAW);
gl.enableVertexAttribArray(0);
gl.vertexAttribPointer(0, 2, gl.FLOAT, false, 16, 0);View on GitHub (pinned to 78fe4bb3fd)
Solutions
- Restart Chrome / the worker to recover a clean context and retry.
- Lower `--concurrency` / framesPerLambda.
- Force software rendering (`--gl=angle --angle-backend=swiftshader`).
- Raise host/Lambda memory if OOM-killed.
- Update GPU drivers / Chrome for persistent failures.
Defensive patterns
Strategy: retry
Validate before calling
function canAllocateVao(canvas: HTMLCanvasElement): boolean {
const gl = canvas.getContext('webgl2');
if (!gl) return false;
const vao = gl.createVertexArray();
const ok = vao !== null;
if (vao) gl.deleteVertexArray(vao);
return ok;
} Try / catch
try {
renderWithLinearProgressiveBlur();
} catch (err) {
if (err instanceof Error && err.message === 'Failed to create WebGL vertex array') {
await restartRendererWorker();
renderWithLinearProgressiveBlur();
} else throw err;
} Prevention
- Cap concurrency to stay under driver object limits.
- Ensure effect cleanup releases VAOs on unmount.
- Recycle workers after GPU-process crashes.
- Force software rendering on unstable GPUs.
When it happens
Trigger: WebGL2 context alive but refusing a VAO — failing context, driver object limit, or GPU memory exhaustion. Same family as the other null-GL-object errors, occurring late in setup after programs/textures already succeeded.
Common situations: High-concurrency renders, long-lived Studio sessions, GPU memory pressure, headless Chrome whose GPU process was OOM-killed.
Related errors
- Failed to create WebGL shader
- Failed to create WebGL program
- Failed to create WebGL vertex array
- Failed to create WebGL buffer
- Failed to create WebGL shader
AI-assisted analysis of remotion-dev/remotion@78fe4bb3fd (2026-08-12).
Data as JSON: /api/errors/16a1c385dbd532f1.
Report an issue: GitHub.