Closed ycw closed 3 weeks ago
cc @dongho-shin - do you want to take a look at this?
StaticGeometryGenerator compare mesh.uuid with cached so it(just change geometry inside of the mesh) may NO_CHANGE for now StaticGeometryGenerator.js near line 238
I think cache comparison method of StaticGeometryGenerator needs to be cleaned up or refactored once.
I took a look at the cache a bit more and found a few issues. It should be fixed in #647. It would be great if you guys could try it to make sure it fixes the issue.
Hopefully in the future we won't have to rely on a full scene static geometry generator - which is a fairly complex to run quickly - but that might be a bit further out.
@ycw I've just published v0.0.23 if you'd like to update the three.js editor. Thanks again for the report and repro.
Describe the bug
setScene()
ignoresmesh.geometry
reassignment in the following situation:Expected behavior
I expected that pathtracer honors
mesh.geometry
reassignment.Workarounds
Renews mesh uuid right after assigning new geometry.
Screenshots and Demos
https://jsfiddle.net/0kyq5g7d/1
https://github.com/gkjohnson/three-gpu-pathtracer/assets/1063018/b9a5ab21-be92-4428-ab14-456cf163b534
Packages