Is there any way to run a vertex shader (calculating around 100-1000 individual vec3), recovering the results in GDScript?
Hacky/workaround stuff is okay.
Summary: I have a function that takes a point in 3D space (plus a bunch of other parameters) as an input and generates an ordered list of 3D points as an output. Each input is independent of others and can be parallelized, but the points for a given input cannot be calculated in parallel.
Background/why: I am trying to write a differential equation integrator for a VR physics visualization that can integrate starting from many points at the same time to draw field lines. I have a proof of concept running on CPU, but it's not very fast and is 100% doable with a compute shader, but as far as I know, compute shaders will only be supported in Godot 4.x and I can't wait until 4.x stabilizes for this project. In some sense, this is an attempt at a port (with improvements) of a compute shader I have access to in Unity.
Things I've looked into: I believe the current way to get data out of "compute shaders" in Godot is to write to textures. I haven't tried this yet, but if this is the best approach at the moment, I'll go ahead and do it this way. I want to check that I'm not missing something important or shooting myself in the foot...
Thank you!