WasmGPU.texture¶
Summary¶
WasmGPU.texture is the texture factory facade. It creates asynchronous 2D texture objects from encoded bytes, URLs, or pre-decoded ImageBitmap sources; returned textures expose upload state, views, samplers, and explicit destruction.
Syntax¶
Available APIs¶
- texture.create2D creates a
Texture2Dfrom its descriptor. - texture.create2D#ensureUploaded awaits upload completion.
- texture.create2D#getView and texture.create2D#getSampler expose GPU binding resources.
- texture.create2D#destroy releases texture-owned GPU resources.