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

BatchedMesh: Fix exception when using Geometry with InterleavedBuffers #27978

Merged
merged 1 commit into from Mar 24, 2024

Conversation

marwie
Copy link
Contributor

@marwie marwie commented Mar 23, 2024

Fixed #27973

Description

Adding geometry that has interleaved buffers currently throws because setUsage is not defined on the InterleavedBufferAttribute.
The PR enforces dstAttribute to new BufferAttribute and removes the call to setUsage as suggested by @gkjohnson

This contribution is funded by 🌵 Needle

Copy link

📦 Bundle size

Full ESM build, minified and gzipped.

Filesize dev Filesize PR Diff
670.9 kB (166.3 kB) 670.9 kB (166.3 kB) -31 B

🌳 Bundle size after tree-shaking

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

Filesize dev Filesize PR Diff
450.9 kB (108.9 kB) 450.9 kB (108.9 kB) +0 B

@gkjohnson
Copy link
Collaborator

I haven't tested it but this looks good to me.

@Mugen87 Mugen87 added this to the r163 milestone Mar 24, 2024
@Mugen87 Mugen87 merged commit 02c38a9 into mrdoob:dev Mar 24, 2024
12 checks passed
marwie added a commit to needle-tools/three.js that referenced this pull request Mar 24, 2024
marwie added a commit to needle-tools/three.js that referenced this pull request Mar 24, 2024
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.

BatchedMesh: Exception with InterleavedBufferAttribute
3 participants