{"record":{"id":"c4e41ca4d3e538ac","repo":"remotion-dev/remotion","slug":"dot-grid-shader-compile-failed-log-no-log","errorCode":null,"errorMessage":"Dot grid shader compile failed: ${log ?? '(no log)'}","messagePattern":"Dot grid shader compile failed: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/effects/src/dot-grid.ts","lineNumber":166,"sourceCode":"\tuInvert: WebGLUniformLocation | null;\n};\n\nconst compileShader = (\n\tgl: WebGL2RenderingContext,\n\ttype: number,\n\tsource: string,\n): WebGLShader => {\n\tconst shader = gl.createShader(type);\n\tif (!shader) {\n\t\tthrow new Error('Failed to create WebGL shader');\n\t}\n\n\tgl.shaderSource(shader, source);\n\tgl.compileShader(shader);\n\tif (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {\n\t\tconst log = gl.getShaderInfoLog(shader);\n\t\tgl.deleteShader(shader);\n\t\tthrow new Error(`Dot grid shader compile failed: ${log ?? '(no log)'}`);\n\t}\n\n\treturn shader;\n};\n\nconst linkProgram = (\n\tgl: WebGL2RenderingContext,\n\tvs: WebGLShader,\n\tfs: WebGLShader,\n): WebGLProgram => {\n\tconst program = gl.createProgram();\n\tif (!program) {\n\t\tthrow new Error('Failed to create WebGL program');\n\t}\n\n\tgl.attachShader(program, vs);\n\tgl.attachShader(program, fs);\n\tgl.linkProgram(program);","sourceCodeStart":148,"sourceCodeEnd":184,"githubUrl":"https://github.com/remotion-dev/remotion/blob/78fe4bb3fdb5a2cd68724393d63cb223db333fa7/packages/effects/src/dot-grid.ts#L148-L184","documentation":"Thrown by dot-grid's compileShader helper after gl.getShaderParameter returns a failed COMPILE_STATUS. The message embeds the GLSL info log from the driver. Because the vertex and fragment shaders are bundled constants, a compile failure almost always indicates a driver bug, a non-conformant WebGL2 implementation, or GLSL ES 3.00 unsupported on the device.","triggerScenarios":"The bundled DOT_GRID_VS or DOT_GRID_FS fails to compile on the user's GPU/driver. Typical of outdated mobile GPUs, virtualized GPUs, or buggy drivers that reject valid #version 300 es GLSL. The info log in the error message names the offending line/feature.","commonSituations":"Older Android GPUs with stale drivers; virtual machines with passthrough GL; remote desktops over RDP; browsers falling back to a software rasterizer that drops precision qualifiers; very old Intel integrated GPUs.","solutions":["Read the embedded info log to identify which GLSL line/feature the driver rejected.","Update GPU drivers and the browser; retry on a different device or browser.","For headless/CI, switch to a SwiftShader software renderer which has conformant GLSL ES 3.00 support.","If the log points to a genuine bug in the bundled shader, file a Remotion issue with the full log and GPU/driver details."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n  state = dotGrid().setup(canvas);\n} catch (err) {\n  if (err instanceof Error && /shader compile failed/i.test(err.message)) {\n    console.error('Driver rejected dot-grid GLSL:', err.message);\n    // fall back to a CSS / SVG dot grid, or skip the effect\n  } else {\n    throw err;\n  }\n}","preventionTips":["Capture the full info log from the error message when reporting issues.","Test on the target GPU/driver during development, not only on the dev machine.","For headless runs, use a conformant software renderer (SwiftShader).","Keep GPU drivers and the browser current."],"tags":["webgl2","dot-grid","shader","glsl","gpu-driver","compile"],"backgroundTag":null,"analyzedSha":"78fe4bb3fdb5a2cd68724393d63cb223db333fa7","analyzedAt":"2026-08-12T17:18:50.444Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}