Godot Version
4.3
Question
I noticed that the Input node’s “NodePositionWorld” only gives the world position of the object rather than each fragment position.
Anyone know if there is a way to get the fragment position in world space?
4.3
I noticed that the Input node’s “NodePositionWorld” only gives the world position of the object rather than each fragment position.
Anyone know if there is a way to get the fragment position in world space?
You need to use the depth buffer, to undo the screen space transform of the fragment.
These nodes?
Still not seeming to do the trick
That looks like it should work. Although since you say it doesn’t work, I wonder if Godot 4.3 reverse Z buffer change broke it.
… Yeah it could be calculating the depth wrong I don’t see a commit to update it when it was integrated.
It does say here if the underlying shader uses the projection matrix to transform the depth texture it should be okay.