UNPKG

playcanvas

Version:

PlayCanvas WebGL game engine

4 lines (2 loc) 501 B
var gsplatDataVS = "\nuniform highp usampler2D transformA;\nuniform highp sampler2D transformB;\nuint tAw;\nvec3 readCenter(SplatSource source) {\n uvec4 tA = texelFetch(transformA, source.uv, 0);\n tAw = tA.w;\n return uintBitsToFloat(tA.xyz);\n}\nvoid readCovariance(in SplatSource source, out vec3 covA, out vec3 covB) {\n vec4 tB = texelFetch(transformB, source.uv, 0);\n vec2 tC = unpackHalf2x16(tAw);\n covA = tB.xyz;\n covB = vec3(tC.x, tC.y, tB.w);\n}\n"; export { gsplatDataVS as default };