Creates a WebGL2 renderer, or returns null when the browser cannot run one (no WebGL2, or no rendering to float textures), so callers can fall back to the pipeline's run.
null
run
const gpu = createGpuRenderer({ canvas: view });if (gpu) { gpu.setImage(img); slider.oninput = () => gpu.render(current()); // full size, every move} Copy
const gpu = createGpuRenderer({ canvas: view });if (gpu) { gpu.setImage(img); slider.oninput = () => gpu.render(current()); // full size, every move}
Creates a WebGL2 renderer, or returns
nullwhen the browser cannot run one (no WebGL2, or no rendering to float textures), so callers can fall back to the pipeline'srun.