Welcome, Guest.
Username: Password: Remember me

TOPIC: Shader activation on ingame depth

Shader activation on ingame depth 2 years 3 months ago #1

I apologize if this has already been covered, I didn't see it and I'm super curious. :cheer:

So, when making some shaders a thought came into my head because I had a nice effect ingame, but it was affecting the map and the menu.

Shader1 = Ingame World
Shader2 = Map/Menus

By using depthvalues that return either as 0 or a number less than a threshold value we could have shaders that dynamically switch for menus without manually having to do so. Would be great for some older games that have 2D textures for menus/maps.

Is there any way at all for me to make a call and get the return value of the depth of the current scene and switch the preset based on that? It'd be even more awesome if I could based on X/Y screen positions. :whistle:
The administrator has disabled public write access.