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

Reuse "added" and "removed" event #17224

Merged
merged 2 commits into from
Aug 10, 2019
Merged

Reuse "added" and "removed" event #17224

merged 2 commits into from
Aug 10, 2019

Conversation

gkjohnson
Copy link
Collaborator

As discussed here.

Share the "added" and "removed" events across dispatches in Object3D to cut down on allocation when adding and removing objects a lot. The pattern works in this case because no fields are changed on the object between dispatches -- I wonder if there's a way to extend this to cases where event data must change?

@mrdoob mrdoob added this to the r108 milestone Aug 10, 2019
@mrdoob mrdoob merged commit 96e0a52 into mrdoob:dev Aug 10, 2019
@mrdoob
Copy link
Owner

mrdoob commented Aug 10, 2019

Thanks!

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.

2 participants