Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Screen-reading (postprocessing) shaders makes Volumetric Fog visible through walls #76780

Closed
Donitzo opened this issue May 6, 2023 · 1 comment

Comments

@Donitzo
Copy link

Donitzo commented May 6, 2023

Godot version

4.0.1

System information

Windows 11

Issue description

When using a screen-reading shader in conjunction with environmental volumetric fog, there is a very clear difference in the way scene looks without and with the shader. The fog light emission is visible through walls.

screen-reading-bug

I would assume some sort of information is lost when the scene is re-rendered through a screen-reading shader. I have tried writing the original depth in the shader as well but with the exact same result.

I understand that it is possible this isn't a bug but may actually just be a technical limitation of some kind.

Steps to reproduce

Use volumetric fog together with a passthrough screen-reading shader. Add a light behind a wall.

Minimal reproduction project

FogTest.zip

@Calinou
Copy link
Member

Calinou commented May 6, 2023

Using SCREEN_TEXTURE makes the material transparent, which makes it not draw to the depth buffer. As a result, transparency sorting issues are expected to occur.

See godotengine/godot-proposals#2196.

@Calinou Calinou closed this as not planned Won't fix, can't repro, duplicate, stale May 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants