MCPcopy Index your code
hub / github.com/processing/p5.js / uploadTextureFromSource

Method uploadTextureFromSource

src/webgpu/p5.RendererWebGPU.js:2452–2462  ·  view source on GitHub ↗
({ gpuTexture }, source)

Source from the content-addressed store, hash-verified

2450 }
2451
2452 uploadTextureFromSource({ gpuTexture }, source) {
2453 this.queue.copyExternalImageToTexture(
2454 { source },
2455 { texture: gpuTexture },
2456 [source.width, source.height]
2457 );
2458
2459 // Force submission to ensure texture upload completes before usage
2460 this._hasPendingDraws = true;
2461 this.flushDraw();
2462 }
2463
2464 uploadTextureFromData({ gpuTexture }, data, width, height) {
2465 this.queue.writeTexture(

Callers

nothing calls this directly

Calls 1

flushDrawMethod · 0.95

Tested by

no test coverage detected