Currently, I am using the three.js collada loader to bring in an .dae file that includes a texture (.png) image. The challenge I am facing involves replacing this original .png file with a new texture generated from a canvas element and saved in .png format. To see the changes reflected in the render, I have discovered that clearing the cache does the trick (simply saving the new texture with the same filename as the original). However, how can I ensure that the updated texture is recognized and rendered without requiring users to clear their cache manually?
I am exploring solutions where the new texture created replaces the old one seamlessly, triggering a re-render of the collada file automatically when a user interacts with a button to display the modified box. Any advice on implementing this feature would be greatly appreciated.