UNPKG

playcanvas

Version:

PlayCanvas WebGL game engine

19 lines (17 loc) 621 B
var gsplatWorkBufferVS = ` var center: texture_2d<uff>; var covA: texture_2d<uff>; var covB: texture_2d<uff>; var splatColor: texture_2d<uff>; fn readCenter(source: ptr<function, SplatSource>) -> vec3f { return textureLoad(center, source.uv, 0).xyz; } fn readCovariance(source: ptr<function, SplatSource>, cov_A: ptr<function, vec3f>, cov_B: ptr<function, vec3f>) { *cov_A = textureLoad(covA, source.uv, 0).xyz; *cov_B = textureLoad(covB, source.uv, 0).xyz; } fn readColor(source: ptr<function, SplatSource>) -> vec4f { return textureLoad(splatColor, source.uv, 0); } `; export { gsplatWorkBufferVS as default };