molstar
Version:
A comprehensive macromolecular library.
5 lines (4 loc) • 567 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.check_picking_alpha = void 0;
exports.check_picking_alpha = "\nfloat viewZ = depthToViewZ(uIsOrtho, fragmentDepth, uNear, uFar);\nfloat fogFactor = smoothstep(uFogNear, uFogFar, abs(viewZ));\nfloat alpha = (1.0 - fogFactor) * uAlpha;\n// if not opaque enough ignore so the element below can be picked\nif (uAlpha < uPickingAlphaThreshold || alpha < 0.1) {\n #ifdef dTransparentBackfaces_opaque\n if (!interior) discard;\n #else\n discard;\n #endif\n}\n";
;