fand / vfx-js

WebGL effects made easy.
https://amagi.dev/vfx-js
626 stars 19 forks source link

fix: recreate CanvasTexture in rerenderTextElement #54

Closed fand closed 3 months ago

fand commented 3 months ago

This PR fixes VFXSpan etc not updating the contents correctly.

Three.js doesn't support updating texture data if the texture size has been changed. This change was introduced in r135: https://github.com/mrdoob/three.js/issues/23164#issuecomment-1007226703

So we have to create textures every time we need to update the contents of VFXSpan etc.

Changes

vercel[bot] commented 3 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-vfx-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 8, 2024 8:49am