@babylonjs/viewer
Version:
The Babylon Viewer aims to simplify a specific but common Babylon.js use case: loading, viewing, and interacting with a 3D model.
3 lines (2 loc) • 802 B
JavaScript
import{S as e}from"./index-Bw2N6w1y.esm.min.js";const r="iblVoxelGrid2dArrayDebugPixelShader",o="precision highp sampler2DArray;varying vec2 vUV;uniform sampler2DArray voxelTexture;uniform sampler2D textureSampler;uniform int slice;void main(void) {ivec3 size=textureSize(voxelTexture,0);float dimension=sqrt(float(size.z));vec2 samplePos=fract(vUV.xy*vec2(dimension));int sampleIndex=int(floor(vUV.x*float(dimension))+floor(vUV.y*float(dimension))*dimension);glFragColor.rgb=texture(voxelTexture,vec3(samplePos.xy,sampleIndex)).rrr;glFragColor.a=1.0;glFragColor.rgb+=texture(textureSampler,vUV.xy).rgb;}";e.ShadersStore[r]||(e.ShadersStore[r]=o);const i={name:r,shader:o};export{i as iblVoxelGrid2dArrayDebugPixelShader};
//# sourceMappingURL=iblVoxelGrid2dArrayDebug.fragment-DrZ22IIh.esm.min.js.map