Where to find more info on Godot 4 shader?
Asked Answered
V

4

0

What are the changes made in Godot4 shader apart from name changes from doc?

I am failing to convert water shaders from 3 to 4 by changing the names. But it runs It either appears black, white, no vertex movements..etc. I am wondering if there are other tweaks in order to make them work in 4beta.

I'm looking specifically at 3d water, thank you.

Vested answered 7/12, 2022 at 3:40 Comment(0)
K
0

Share the shader here, you'll likely get more replies that way.

Format as:

```
lines of(code):
  here
```
Kraut answered 7/12, 2022 at 7:8 Comment(0)
V
0

Kraut

I have made an issue before that I couldn't get the foam issue fix.

https://mcmap.net/q/481/godot-how-to-fix-foam-issue-in-3d-water-shader

(I'd appreciated if anyone have any guidance to how to fix the foam issue in that post.)

For this post though I am wondering if there are changes to Godot4 shader under the hood that I should be aware of? I feel like I am unable to convert Godot3 shader to 4 correctly by changing the names alone. (I failed with other water shaders as well).

Vested answered 7/12, 2022 at 10:33 Comment(0)
K
0

Vested I feel like I am unable to convert Godot3 shader to 4 correctly by changing the names alone.

Yes, which is why I said to share the shader source, many of us are likely still just getting started with godot 4 so some here might help even without knowing the answer cause they'd be curious to explore this as well.

Kraut answered 7/12, 2022 at 22:59 Comment(0)
V
0

Found some info on doc. I think something to do with depth buffer/texture that is causing the problem.

https://docs.godotengine.org/en/latest/tutorials/shaders/advanced_postprocessing.html

When displaying depth directly from the DEPTH_TEXTURE, everything will look almost white unless it is very close

I'm not very good at coding let alone shader coding. I have to go through this word by word slowly 🥲

Vested answered 8/12, 2022 at 3:9 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.