{"record":{"id":"8e7b9d8c378297ed","repo":"perspective-dev/perspective","slug":"density-message","errorCode":null,"errorMessage":"Density: ${message}","messagePattern":"Density: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/viewer-charts/src/ts/charts/cartesian/glyphs/density.ts","lineNumber":618,"sourceCode":"\n        if (requested === \"extreme\" && !glManager.isWebGL2) {\n            this.warnDowngradeOnce(\n                cache,\n                \"extreme mode requires WebGL2 (for MAX blend and a second color attachment); falling back to mean.\",\n            );\n            return \"mean\";\n        }\n\n        return requested;\n    }\n\n    private warnDowngradeOnce(cache: DensityCache, message: string): void {\n        if (cache.signedDowngradeWarned) {\n            return;\n        }\n\n        cache.signedDowngradeWarned = true;\n        console.warn(`Density: ${message}`);\n    }\n\n    /**\n     * Shared splat → resolve pipeline. `dispatchSplats(cb)` iterates\n     * the series ranges the caller wants drawn, invoking\n     * `cb(slotOffset, count)` per range — `drawSeries` passes a single\n     * range, `draw` iterates every series. Internally branches on the\n     * active color mode: density/mean/signed share the single-target\n     * heat-only pass, `extreme` runs either an MRT single-pass or two\n     * sequential passes depending on extension support.\n     */\n    private runSplatAndResolve(\n        chart: CartesianChart,\n        glManager: WebGLContextManager,\n        cache: DensityCache,\n        projection: Float32Array,\n        dispatchSplats: (\n            cb: (slotOffset: number, count: number) => void,","sourceCodeStart":600,"sourceCodeEnd":636,"githubUrl":"https://github.com/perspective-dev/perspective/blob/11c8238c0c9c0b9e490b5a6a2dc277afad1e980a/packages/viewer-charts/src/ts/charts/cartesian/glyphs/density.ts#L600-L636","documentation":"One-time console warning from the density chart renderer when a requested signed-density mode must be downgraded. Specifically, 'extreme' mode needs WebGL2 features (MAX blend and a second color attachment); on a WebGL1 context the renderer silently falls back to 'mean' and warns once per density cache.","triggerScenarios":"Thrown at packages/viewer-charts/src/ts/charts/cartesian/glyphs/density.ts:618 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Ensure the browser/context provides WebGL2 (update browser or GPU drivers)","Check that the canvas context creation isn't forcing WebGL1 via context attributes","Accept the fallback to mean mode, which renders correctly with reduced fidelity","Request or configure a mode supported by WebGL1 if the target environment cannot provide WebGL2"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"11c8238c0c9c0b9e490b5a6a2dc277afad1e980a","analyzedAt":"2026-09-09T00:35:19.377Z","contentChangedAt":"2026-09-09T00:35:19.377Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}