You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As of now, the library uses two monolithic shader chunks that are injected into the built-in materials of Three.js through three-custom-shader-material. All animation input is passed to this shader code by way of vertex attributes attached to the material.
This approach has a couple of limitations:
The same shader code needs to support all possible effects, which is bound to make it more complex than we'd want it to be.
Since the only way to configure it is through uniforms and attribute buffers, we will quickly run into their respective limits.
All animations are currently implemented using linear interpolation; supporting easing functions would need additional uniforms/buffers; see above.
To be:
For these reasons (and, admittedly, because it feels like a fun challenge), one of the goals for this library has always been to change this into a system that generates per-effect shader code. Basically, each effect would declaratively build a pipeline of operations that would then be compiled to shader code. The individual steps might be:
Billboarding
Velocity + Acceleration/Damping (with or without easing)
Animating Opacity
Animating Color
etc.
The text was updated successfully, but these errors were encountered:
As is:
As of now, the library uses two monolithic shader chunks that are injected into the built-in materials of Three.js through three-custom-shader-material. All animation input is passed to this shader code by way of vertex attributes attached to the material.
This approach has a couple of limitations:
To be:
For these reasons (and, admittedly, because it feels like a fun challenge), one of the goals for this library has always been to change this into a system that generates per-effect shader code. Basically, each effect would declaratively build a pipeline of operations that would then be compiled to shader code. The individual steps might be:
The text was updated successfully, but these errors were encountered: