Skip to content

WebGLRenderer: Unify cubemaps and cubeuvmaps into WebGLEnvironments#32792

Merged
mrdoob merged 1 commit intodevfrom
webgl-envmaps
Jan 19, 2026
Merged

WebGLRenderer: Unify cubemaps and cubeuvmaps into WebGLEnvironments#32792
mrdoob merged 1 commit intodevfrom
webgl-envmaps

Conversation

@mrdoob
Copy link
Owner

@mrdoob mrdoob commented Jan 19, 2026

Consolidates WebGLCubeMaps and WebGLCubeUVMaps into a single WebGLEnvironments class with a cleaner API.

Before:

const envMap = ( material.isMeshStandardMaterial ? cubeuvmaps : cubemaps ).get( texture );

After:

const envMap = environments.get( texture, usePMREM );

@mrdoob mrdoob added this to the r183 milestone Jan 19, 2026
@github-actions
Copy link

github-actions bot commented Jan 19, 2026

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 355.82
84.56
355.77
84.57
-54 B
+14 B
WebGPU 621.5
172.57
621.5
172.57
+0 B
+0 B
WebGPU Nodes 620.1
172.33
620.1
172.33
+0 B
+0 B

🌳 Bundle size after tree-shaking

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

Before After Diff
WebGL 488.06
119.45
488.01
119.48
-48 B
+30 B
WebGPU 691.97
187.85
691.97
187.85
+0 B
+0 B
WebGPU Nodes 641.77
175.02
641.77
175.02
+0 B
+0 B

@mrdoob mrdoob changed the title WebGLRenderer: Unify cubemaps and cubeuvmaps into WebGLEnvMaps. WebGLRenderer: Unify cubemaps and cubeuvmaps into WebGLEnvironments Jan 19, 2026
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@mrdoob mrdoob merged commit be02a54 into dev Jan 19, 2026
10 checks passed
@mrdoob mrdoob deleted the webgl-envmaps branch January 19, 2026 07:35
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.

1 participant