Looking for a solution to achieve the following effect:
I’d need multiple spheres displacing a single plane mesh underneath in real time, think gravity well:
- The size of the plane and the spheres (and their number) is dynamic and will affect the strength of the displacement
- The distortions will overlap but will not be cumulative on the Z axis (ideally, but not really a must have)
- The effect is purely visual, no collision, shadowcasting or additional player interaction is necessary
- Does not need to be particularly performant
- Does not need to be very accurate
- I was hoping to achieve it via materials
I’ve been experimenting with *WorldPositionOffset *and SphereGradient-2D and it’s easy enough to pull it off for a single instance.
Multiple displacement effects are, of course, doable if I simply duplicate the nodes and apply unique coordinates but that’s cumbersome
and the final number of the displacements is not fixed. And it does not feel like the right way do it anyway.
How do I send a bunch of coordinates to the material in real time? Is a dynamic texture implemented through C++ the only way forward?
Out of the box ideas are welcome, too!