Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PMREMGenerator: Add size and position options to fromScene(). #30477

Merged
merged 2 commits into from
Feb 9, 2025

Conversation

Mugen87
Copy link
Collaborator

@Mugen87 Mugen87 commented Feb 7, 2025

Fixed #30071.

Description

The PR is an alternative implementation to #30334 and introduces a new options parameter to PMREMGenerator.fromScene() that allows to customize the size of the PMREM as well as the position of the internal cube camera.

@Mugen87 Mugen87 added this to the r174 milestone Feb 7, 2025
Copy link

github-actions bot commented Feb 7, 2025

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 336.12
78.22
336.28
78.27
+158 B
+52 B
WebGPU 517.54
143.78
517.73
143.83
+186 B
+57 B
WebGPU Nodes 517.01
143.66
517.2
143.72
+186 B
+55 B

🌳 Bundle size after tree-shaking

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

Before After Diff
WebGL 465.17
112.09
465.32
112.14
+159 B
+46 B
WebGPU 589.44
159.86
589.63
159.95
+187 B
+87 B
WebGPU Nodes 544.8
149.41
544.99
149.48
+187 B
+70 B

@sunag sunag merged commit 57e59a9 into mrdoob:dev Feb 9, 2025
12 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.

Adding a position options for the PMREM fromScene generation
2 participants