- Home /
Caustic underwater effect
I want to make a as realistic as possible underwater effect. Any ideas are welcome.
I have been working with fog but that isn't good enough. Now I figured out that a caustic effect would help too. I have been googling for it and expect for one downloadable project I haven't found any tutorial for it.
So my question is how do I make a caustic effect in unity3d(I'm working with C#).
Any other tips for making the underwater effect as realistic as possible are very appreciated.
Thanks in advance
Answer by Hoeloe · Oct 01, 2013 at 12:20 AM
One way you can do this (far from the best way, but it's quick, easy and it works) is to use Unity's built-in projectors. There is a shader called Projector/Additive, which is helpful. Then, you just get an animated texture, save each frame as a separate image, and swap out the texture on the material during run time. This will display the caustic, animated, mapping to the sea/river/lake etc. bed. This method will also overlay the caustic on top of dynamic objects, like the player, who might be underwater, too.
To make an even more realistic effect, you might want to look into making godrays to go along with it, which will give you the shafts of light you sometimes see underwater.
Thanks for you respond I have tried it and it worked pretty well. Except for the Projector/Additive thing. I worked with normal light projector and a script I found earlier which didn't made any sense to me till now.
http://answers.unity3d.com/questions/39572/using-a-projector-to-place-a-animated-image-on-a-t.html
I'm still not quite satisfied about the water but my question about the caustic has been answered.
For those who don't know where to find the projector. You can import the package under Assets > import package > projectors
Well, the Additive one is more a matter of preference, and it depends on your caustic texture. I found it gave a good effect when I used it, but you may prefer others.
I found a little problem with the display of the caustic. If I get lower on the terrain it will give some empty blocks without the caustic effect any idea on how to fix it?
Your answer
Follow this Question
Related Questions
Subnautica like underwater effect / rays 0 Answers
underwater shader 1 Answer
Mask water for underwater effects 0 Answers
How to get caustics only show underwater? 1 Answer
Why is my Pro Water Material Grey? 1 Answer