{"record":{"id":"4eb96af33b1a8777","repo":"remotion-dev/remotion","slug":"white-balance-shader-link-failed-log-no-lo","errorCode":null,"errorMessage":"White balance shader link failed: ${log ?? '(no log)'}","messagePattern":"White balance shader link failed: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"critical","filePath":"packages/effects/src/white-balance.ts","lineNumber":161,"sourceCode":"\nconst createProgram = (gl: WebGL2RenderingContext): WebGLProgram => {\n\tconst vertexShader = compileShader(gl, gl.VERTEX_SHADER, VERTEX_SHADER);\n\tconst fragmentShader = compileShader(gl, gl.FRAGMENT_SHADER, FRAGMENT_SHADER);\n\tconst program = gl.createProgram();\n\tif (!program) {\n\t\tthrow new Error('Failed to create white balance shader program');\n\t}\n\n\tgl.attachShader(program, vertexShader);\n\tgl.attachShader(program, fragmentShader);\n\tgl.linkProgram(program);\n\tgl.deleteShader(vertexShader);\n\tgl.deleteShader(fragmentShader);\n\n\tif (!gl.getProgramParameter(program, gl.LINK_STATUS)) {\n\t\tconst log = gl.getProgramInfoLog(program);\n\t\tgl.deleteProgram(program);\n\t\tthrow new Error(`White balance shader link failed: ${log ?? '(no log)'}`);\n\t}\n\n\treturn program;\n};\n\nconst createTexture = (gl: WebGL2RenderingContext): WebGLTexture => {\n\tconst texture = gl.createTexture();\n\tif (!texture) {\n\t\tthrow new Error('Failed to create white balance texture');\n\t}\n\n\tgl.bindTexture(gl.TEXTURE_2D, texture);\n\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);\n\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n\tgl.bindTexture(gl.TEXTURE_2D, null);\n\treturn texture;","sourceCodeStart":143,"sourceCodeEnd":179,"githubUrl":"https://github.com/remotion-dev/remotion/blob/78fe4bb3fdb5a2cd68724393d63cb223db333fa7/packages/effects/src/white-balance.ts#L143-L179","documentation":"Thrown by createProgram() in the white balance effect when gl.getProgramParameter(program, gl.LINK_STATUS) returns false. The vertex and fragment shaders compiled individually but failed to link into an executable program. The error includes the GL driver's info log. The shaders are static library constants, so this is a driver/GPU compatibility issue, not a user param issue.","triggerScenarios":"Called from setupWhiteBalance() at packages/effects/src/white-balance.ts:194 via createProgram(gl). Fires when the GL driver cannot link the compiled vertex and fragment shaders — e.g., mismatched in/out declarations from a driver bug, exceeding uniform limits, or a driver-specific linker issue with the white balance shader's color space functions.","commonSituations":"GPU driver bug rejecting valid linked GLSL ES 3.00 programs; constrained hardware with low uniform limits; software rasterizer with incomplete program linker; outdated browser with a WebGL2 backend regression.","solutions":["Update GPU drivers and browser to the latest versions.","Check chrome://gpu for WebGL2 warnings or denylisted features.","For server-side rendering, use the latest @remotion/renderer with its tested bundled Chrome.","Try a different GPU or toggle hardware acceleration to isolate driver vs SwiftShader.","Report with the full info log from the error message and GPU details."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n  const state = setupWhiteBalance(canvas);\n} catch (e) {\n  if ((e as Error).message.startsWith('White balance shader link failed')) {\n    console.warn('GPU driver failed to link white balance program:', (e as Error).message);\n    // fall back to a non-WebGL color correction approach\n  }\n}","preventionTips":["Update GPU drivers and browser to the latest versions.","Test WebGL2 effects in the target environment before deploying.","Check chrome://gpu for WebGL2 compatibility issues."],"tags":["webgl","gpu","shader","glsl","white-balance-effect","driver"],"backgroundTag":null,"analyzedSha":"78fe4bb3fdb5a2cd68724393d63cb223db333fa7","analyzedAt":"2026-08-12T17:18:50.444Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}