three.js icon indicating copy to clipboard operation
three.js copied to clipboard

WebGPURenderer: Rework to use a single renderBundle per Group().static object

Open aardgoose opened this issue 1 year ago • 1 comments

The existing code uses a renderBundle per object. Create a single renderBundle in preparation for bindGroup sorting and setBindGroup() minimisation,using a renderBundle currentSet{} object.

This combined with PR #27388 (single buffer for uniform buffers), I get a Chrome GPU Process frame time reduced from 10ms to 1.5ms.

aardgoose avatar Aug 27 '24 13:08 aardgoose

📦 Bundle size

Full ESM build, minified and gzipped.

Filesize dev Filesize PR Diff
685.4 kB (169.7 kB) 685.4 kB (169.7 kB) +0 B

🌳 Bundle size after tree-shaking

Minimal build including a renderer, camera, empty scene, and dependencies.

Filesize dev Filesize PR Diff
462 kB (111.4 kB) 462 kB (111.4 kB) +0 B

github-actions[bot] avatar Aug 27 '24 13:08 github-actions[bot]