declare const _default: "\n#include \"gsplatPackingPS\"\n\nvar packedTexture: texture_2d<u32>;\n\nuniform means_mins: vec3f;\nuniform means_maxs: vec3f;\n\nuniform scales_mins: f32;\nuniform scales_maxs: f32;\n\nvar<private> packedSample: vec4<u32>;\n\n// read the model-space center of the gaussian\nfn readCenter(source: ptr<function, SplatSource>) -> vec3f {\n\n    packedSample = textureLoad(packedTexture, source.uv, 0);\n\n    let l = unpack8888(packedSample.x).xyz;\n    let u = unpack8888(packedSample.y).xyz;\n    let n = (l * 255.0 + u * 255.0 * 256.0) / 65535.0;\n    let v = mix(uniform.means_mins, uniform.means_maxs, n);\n\n    return sign(v) * (exp(abs(v)) - 1.0);\n}\n\nconst norm: f32 = 2.0 / sqrt(2.0);\n\n// sample covariance vectors\nfn readCovariance(source: ptr<function, SplatSource>, covA_ptr: ptr<function, vec3f>, covB_ptr: ptr<function, vec3f>) {\n    let qdata = unpack8888(packedSample.z).xyz;\n    let sdata = unpack101010(packedSample.w >> 2u);\n\n    let qmode = packedSample.w & 0x3u;\n    let abc = (qdata - 0.5) * norm;\n    let d = sqrt(max(0.0, 1.0 - dot(abc, abc)));\n\n    var quat: vec4f;\n    if (qmode == 0u) {\n        quat = vec4f(d, abc);\n    } else if (qmode == 1u) {\n        quat = vec4f(abc.x, d, abc.y, abc.z);\n    } else if (qmode == 2u) {\n        quat = vec4f(abc.x, abc.y, d, abc.z);\n    } else {\n        quat = vec4f(abc.x, abc.y, abc.z, d);\n    }\n\n    let rot = quatToMat3(quat);\n    let scale = exp(mix(vec3f(uniform.scales_mins), vec3f(uniform.scales_maxs), sdata));\n\n    // M = S * R\n    let M = transpose(mat3x3f(\n        scale.x * rot[0],\n        scale.y * rot[1],\n        scale.z * rot[2]\n    ));\n\n    *covA_ptr = vec3f(dot(M[0], M[0]), dot(M[0], M[1]), dot(M[0], M[2]));\n    *covB_ptr = vec3f(dot(M[1], M[1]), dot(M[1], M[2]), dot(M[2], M[2]));\n}\n";
export default _default;
