MCPcopy
hub / github.com/sparkjsdev/spark / newUint32ArrayTexture

Function newUint32ArrayTexture

src/ExtSplats.ts:928–948  ·  view source on GitHub ↗
(
  data: Uint32Array | null,
  width: number,
  height: number,
  depth: number,
  format: THREE.AnyPixelFormat,
  type: THREE.TextureDataType,
  internalFormat: THREE.PixelFormatGPU,
)

Source from the content-addressed store, hash-verified

926}
927
928function newUint32ArrayTexture(
929 data: Uint32Array | null,
930 width: number,
931 height: number,
932 depth: number,
933 format: THREE.AnyPixelFormat,
934 type: THREE.TextureDataType,
935 internalFormat: THREE.PixelFormatGPU,
936): THREE.DataArrayTexture {
937 const texture = new THREE.DataArrayTexture(
938 data as Uint32Array<ArrayBuffer>,
939 width,
940 height,
941 depth,
942 );
943 texture.format = format;
944 texture.type = type;
945 texture.internalFormat = internalFormat;
946 texture.needsUpdate = true;
947 return texture;
948}

Callers 3

ensureShTexturesMethod · 0.85
updateTexturesMethod · 0.85
ExtSplatsClass · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected