{"record":{"id":"78a95b7dd1c54ee1","repo":"BabylonJS/Babylon.js","slug":"ssr-post-process-this-name-automatic-thickne-78a95b","errorCode":null,"errorMessage":"SSR post process \"${this.name}\": Automatic thickness computation requires that geomDepth and geomBackDepth have the same type (view or screen space depth)!","messagePattern":"SSR post process \"(.+?)\": Automatic thickness computation requires that geomDepth and geomBackDepth have the same type \\(view or screen space depth\\)!","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/dev/core/src/FrameGraph/Node/Blocks/PostProcesses/ssrPostProcessBlock.pure.ts","lineNumber":449,"sourceCode":"            }\r\n\r\n            const geomBackDepthOwnerBlock = this.geomBackDepth.connectedPoint!.ownerBlock;\r\n            if (geomBackDepthOwnerBlock.getClassName() === \"NodeRenderGraphGeometryRendererBlock\") {\r\n                const geometryBackFaceRendererBlock = geomBackDepthOwnerBlock as NodeRenderGraphGeometryRendererBlock;\r\n                if (!geometryBackFaceRendererBlock.reverseCulling) {\r\n                    throw new Error(\r\n                        `SSR post process \"${this.name}\": Automatic thickness computation requires the geometry renderer block for the back depth texture to have reverse culling enabled!`\r\n                    );\r\n                }\r\n\r\n                if (this._frameGraphTask.depthTexture) {\r\n                    const geomDepthOwnerBlock = this.geomDepth.connectedPoint!.ownerBlock;\r\n                    if (geomDepthOwnerBlock.getClassName() === \"NodeRenderGraphGeometryRendererBlock\") {\r\n                        const geomDepthConnectionPointType = this.geomDepth.connectedPoint!.type;\r\n                        const geomBackDepthConnectionPointType = this.geomBackDepth.connectedPoint!.type;\r\n\r\n                        if (geomDepthConnectionPointType !== geomBackDepthConnectionPointType) {\r\n                            throw new Error(\r\n                                `SSR post process \"${this.name}\": Automatic thickness computation requires that geomDepth and geomBackDepth have the same type (view or screen space depth)!`\r\n                            );\r\n                        }\r\n                    }\r\n                }\r\n            }\r\n        }\r\n\r\n        if (this.geomNormal.connectedPoint) {\r\n            if (this.geomNormal.connectedPoint.type === NodeRenderGraphBlockConnectionPointTypes.TextureWorldNormal) {\r\n                this._frameGraphTask.ssr.normalsAreInWorldSpace = true;\r\n                this._frameGraphTask.ssr.normalsAreUnsigned = true;\r\n            }\r\n        }\r\n        if (this.geomDepth.connectedPoint) {\r\n            if (this.geomDepth.connectedPoint.type === NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth) {\r\n                this._frameGraphTask.ssr.useScreenspaceDepth = true;\r\n            }\r","sourceCodeStart":431,"sourceCodeEnd":467,"githubUrl":"https://github.com/BabylonJS/Babylon.js/blob/0592b347b8a4ee0236089ea86a749cacfdb266d8/packages/dev/core/src/FrameGraph/Node/Blocks/PostProcesses/ssrPostProcessBlock.pure.ts#L431-L467","documentation":"When computing SSR thickness automatically, the front depth (geomDepth) and back depth (geomBackDepth) must be expressed in the same space (view-space or screen-space). _buildBlock compares the connection point types and throws if they differ.","triggerScenarios":"Building a graph where geomDepth and geomBackDepth are connected to blocks producing different depth types (e.g. one view-space, one screen-space) while enableAutomaticThicknessComputation is on.","commonSituations":"Mixing outputs from differently configured geometry renderer blocks; swapping one connection after changing depth-type settings on one block only.","solutions":["Make both geometry renderer blocks produce the same depth type (both view or both screen space)","Change the depth-type option on one block to match the other","Disable automatic thickness computation if mixed depth spaces are unavoidable"],"exampleFix":"// before\ngeomFront.useViewSpace = true;\ngeomBack.useViewSpace = false; // mismatched\n// after\ngeomFront.useViewSpace = true;\ngeomBack.useViewSpace = true;","handlingStrategy":"validation","validationCode":"if (ssrBlock.enableAutomaticThicknessComputation && ssrBlock.geomDepth.connectedPoint && ssrBlock.geomBackDepth.connectedPoint) {\n  if (ssrBlock.geomDepth.connectedPoint.type !== ssrBlock.geomBackDepth.connectedPoint.type) {\n    throw new Error('geomDepth and geomBackDepth must have the same depth type');\n  }\n}","typeGuard":"function depthTypesMatch(b) { return b.geomDepth.connectedPoint?.type === b.geomBackDepth.connectedPoint?.type; }","tryCatchPattern":"try { graph.build(); } catch (e) { if (e.message.includes('same type (view or screen space depth)')) { console.error('Align depth-space settings on both geometry renderers'); } else { throw e; } }","preventionTips":["Configure both geometry renderer blocks with identical depth-space options","Compare connection point types in a pre-build validation pass","Document which depth type your SSR setup uses and stick to it"],"tags":["render-graph","ssr","configuration-mismatch"],"backgroundTag":"inconsistent-configuration","analyzedSha":"0592b347b8a4ee0236089ea86a749cacfdb266d8","analyzedAt":"2026-08-30T15:11:20.442Z","schemaVersion":2},"datasetVersion":"2026-08-30T18:17:15.746Z"}