Skip to content

fix: MeshReflectorMaterial creating FBO every re-render #2409

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

Conversation

Nickardson
Copy link
Contributor

Why

The <MeshReflectorMaterial/> had a useMemo referencing a blur array which would be a different object reference every React render, causing the FBO and other expensive things to be recreated every render.

What

Changed the useMemo to check the values of the blur array rather than the array itself.

Checklist

  • Ready to be merged

Copy link

vercel bot commented Apr 5, 2025

@Nickardson is attempting to deploy a commit to the Poimandres Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

codesandbox-ci bot commented Apr 5, 2025

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@CodyJasonBennett CodyJasonBennett merged commit 7d901b5 into pmndrs:master Apr 6, 2025
3 of 4 checks passed
Copy link

github-actions bot commented Apr 6, 2025

🎉 This PR is included in version 10.0.6 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants