Godot Version
4.6
Question
Before you ask. The code is on my work pc and I can’t access that for a few days. Now on to the question. I made a black hole shader in Godot. But I found the minimum amount of raymarching steps I need is 200
. I need this to run in vr lol. Any ideas on how to optimize it mainly replacing the raymarching steps or well more specifically lowering that amount required.
It’s pretty hard to optimize code without seeing it. It would also help to know if this is a canvas or spatial shader. I recommend adapting one of these:
Black Hole Shaders
Blackhole Shaders
It is adapted from one of those but I changed so much that I managed to deoptimize it lol. Ima try and get the code, when I do I will post it here.
1 Like
Doing raymarching in production code is never a good idea. How did you determine the magical number of 200 steps?
Go lower until it breaks lol. My shader code is messy as hell. I’m good at normal code but shaders have never been my thing.