How to dispose textures created by post-processing passes? #2379
hayden2114
started this conversation in
General
Replies: 1 comment
-
You'll want to abstract these passes and properly implement dispose methods on top of them, this way they're called on unmount. I'd recommend using @react-three/postprocessing or Drei#effects that already do this. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I posted the details of this issue on the three.js discourse page, which I'll link below and attach a screenshot for convenience. But basically there are textures being leftover in memory whenever unmounting the effectComposer with outline and shader passes.
I'm using three.js version 131.3 and just using the
extend
function from r3f.Any help or guidance would be appreciated!
https://discourse.threejs.org/t/how-to-dispose-textures-created-by-post-processing-passes/39621
Beta Was this translation helpful? Give feedback.
All reactions