Skip to content

WebGPURenderer: Make device capabilities handling more consistent.#33094

Merged
sunag merged 1 commit into
mrdoob:devfrom
Mugen87:dev5
Mar 1, 2026
Merged

WebGPURenderer: Make device capabilities handling more consistent.#33094
sunag merged 1 commit into
mrdoob:devfrom
Mugen87:dev5

Conversation

@Mugen87

@Mugen87 Mugen87 commented Feb 28, 2026

Copy link
Copy Markdown
Collaborator

Related issue: -

Description

We need to make sure WebGPURenderer better honors the device's capabilities. E.g. similar to WebGLRenderer, it should warn the user when a texture exceeds the maximum supported texture size and perform a resize.

As a preparation for upcoming changes, this PR refactors the limits management by grouping the limit checks in dedicated modules. For that WebGPUCapabilities is introduced that shares the same methods like WebGLCapabilities. Renderer, backends and node builders should not check capabilities by themselves but use the capabilities modules to query limits.

@github-actions

github-actions Bot commented Feb 28, 2026

Copy link
Copy Markdown

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 359.57
85.37
359.57
85.37
+0 B
+0 B
WebGPU 626.97
174.23
627.17
174.29
+196 B
+63 B
WebGPU Nodes 625.55
173.98
625.75
174.05
+196 B
+63 B

🌳 Bundle size after tree-shaking

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

Before After Diff
WebGL 491.31
119.78
491.31
119.78
+0 B
+0 B
WebGPU 700.59
189.23
700.79
189.28
+196 B
+48 B
WebGPU Nodes 649.8
176.59
649.99
176.64
+196 B
+52 B

Comment thread src/renderers/webgpu/utils/WebGPUCapabilities.js Fixed
@sunag sunag added this to the r184 milestone Mar 1, 2026
@sunag sunag merged commit 7bbb584 into mrdoob:dev Mar 1, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants