Download

Underwater technique

Hi fellow UE4 colleagues,

I’m trying to re-create an underwater scene in UE4. In the screenshot below, the forefront (corals) are clear as the camera proceeds thru the reef, but the background is blue and faded as the camera moves. Does anyone know what setting controls this? Is it a fog? A post setting? DoF?

Also, if anyone has any advice on how to create a good way of creating an underwater look, I’d appreciate any advice.

Thanks in advance!

Doug

Hey Doug,

I have created a similar effect for my ocean system (and then forgot to include it… Doh!), basically you would use a Post Process volume and make it’s size fill the area that is underwater.

You can use the Scene Color to adjust the blue water effect, and add in a Gaussian or Bokeh depth of field (I found Gaussian works better in my case) effect to blur out at a distance. For an added effect you can also try using an ExponentialHeightFog actor, lower it down so it affects the same area as the PP and adjust the fog density, as well as other properties such as directional inscattering colors. To go even further you can create “GodRays” similar to the one in the Content Examples project to have light beams shining through the water (in the blueprints folder of the Content Examples).

I created a screenshot for myself yesterday of the PP volume so I could copy it over to another project, it won’t work exactly how you want but hopefully gives you some ideas on which settings to use (for your scene you might not want to use the Vignette, or if you do make the color brighter). Hope it helps! :slight_smile:

Hi DotCam,

How ironic! I was just going thru your AMAZING work for the water surface! It’s such a great contribution to the community and I really welcome the chance to learn from it!

First, thanks so much for posting your settings for post!

I’ve used much of the same settings that you outline (DoF, tint, godray_bp, vignette (which I later removed for my purposes), but still just can’t get the effect that I’m looking for. I’m going to just keep tweaking ( I did find that an ExponentialHeightFog helps in my simulation), and keep going. I’m also going to look at your values a bit more closely. Realizing that they might not work well in my scene, but maybe my variables are off tremendously.

Again, thanks for helping!! Your work is amazing.

Doug

No problem, hope you find it useful! :slight_smile:

One other thing I forgot to mention is you can use Post Process materials to affect the scene as well, you add them into the PP in the Misc section under “Blendables”. Here is the documentation on them:

I am not too happy with the underwater PP effect currently, it works but could look a lot better, so I plan to give PP Materials a try. I found a tutorial HERE on creating a water drop effect on the camera lens (which will be used when the camera leaves the water, have some water drip down the screen), it was the first PP Material I have created, but I can see many uses for them when it comes to water. I’ll post the material here for you if it is any good for an underwater effect. :slight_smile:

That PP Material tut looks really good. I’ll see what I can do with it. Like you, my current pp looks OK, but not great. Can you share a screen of where you’re at with the look?

It really isn’t much to look at, it was something I put together quickly to make it look somewhat like water and haven’t gotten around to fixing it yet. I will be working on it some more when I get everything into the demo project, I will probably only use the Gaussian blur settings (which are a bit too extreme right now) and modify the rest with a PP material of some sort.

I don’t really have anything to look at underwater except these rocks right now. I’m also getting way too much shadow from the water plane, it needs adjusting as well so it’s pretty dark down there. :slight_smile:

Hi dougb,

I actually know the effect you are looking for. It’s a post process material effect. I created this once a few years ago. It’s been awhile since I’ve looked at it so I’ll have to dig around my hard-drive to find it but will post it when I do. The basic idea is this: http://udn.epicgames.com/Three/MaterialsCompendium.html#SceneDepth

I have also setup a quick material in UE4 to test and can confirm that it does still work. Here is the material similar to what you want. You will probably have to play with the numbers and stuff a bit. Hope this helps!

Underwater_PP.JPG

EMcNINe,

That’s EXACTLY what I was looking for!! Thanks so much for pointing me in the right direction and providing me with the materials layout! Working hard on UE4 so that I can start giving back to the community in the way that you guys do.

Best,
Doug

Hey thanks EMcNine! I knew it must be a PP Material, this will work great! Thank you :slight_smile:

Here is the UE4 documentation on SceneDepth (pretty much the same, just thought I would add it in):

Using multiply node on UE14.3 shows an error, what other node instead multiply can I use?

Holy mother of thread necros.

How come this changes colors for everything? How do i keep the close items color?