# Shallow Ocean Shader

**URL:** <https://forums.unrealengine.com/t/shallow-ocean-shader/7704>\
**Category:** Game Development\
**Tags:** unreal-engine, Showcase\
**Created:** [July 16, 2014, 6:28pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704 "2014-07-16T18:28:24Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mikepote](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mikepote](https://forums.unrealengine.com/u/Mikepote)\
**Post date:** [July 16, 2014, 6:28pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/1 "2014-07-16T18:28:24Z")

</div>

**EDIT:** Download the shader here:

Hey guys, I recently made a cool material I’d like to bring to the show and tell:

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/5/8/3588f3fd6c847371f4e95253ebb17f354ed1016a.jpeg "Unreal Engine 4 - Shallow Sea Shader") ](https://www.youtube.com/watch?v=QiVri8QJSPo)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/d/e/7decac863bda026de8e5512535b19d76e50b8c9a.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/9/3/59345ed63b6fa30aadac01521127ea666beb2a2a.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/e/d/9/ed918e5c913daf8e1b1f9ede60f3cc7c84edc0f2.jpeg)  
Some early screenshots:

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/9/0/7902cb853e7d10a2b505804cc20e1579a0e1601a.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/1/c/c1c56c87789233c6a708267696debd74550f0ae0.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/0/a/80a15e5acb45f46be9f23b84e1a4ef07737c8f5d.jpeg)  
So it’s a single material that takes in a heightmap and a Sea Level parameter, and renders out a water part with foam and underwater depth, and a land part with rock and greenery.

It takes advantage of a very cool function in UE4 called BumpOffset which does fake depth adjustment - like what they use for Parallax Bumpmapping. So the dark underwater areas look as if they are deeper than the lighter, shallower areas, when you view it from different angles.

Here is the first version of the Material Blueprint with comments:

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/2/a/22ae6656232ddbe479094c900e677d8e2cbfb3f7.jpeg)  
If anyone knows an easy way to export out a blueprint, I’ll post the updated version with sea foam and some visual improvements.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_0df12f74](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_0df12f74](https://forums.unrealengine.com/u/anonymous_user_0df12f74)\
**Post date:** [July 16, 2014, 6:42pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/2 "2014-07-16T18:42:17Z")

</div>

Nice work Mikepote, Looks great! 🙂  
I would be interested to see how looks in-game as well, do you have any screenshots of it applied to a surface?

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2793493e1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2793493e1](https://forums.unrealengine.com/u/anonymous_user_2793493e1)\
**Post date:** [July 16, 2014, 6:46pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/3 "2014-07-16T18:46:43Z")

</div>

Amazing! Can you share the Material?

---

<div class="post-metadata">

**Author:** ![ufna](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ufna/32/1194675_2.png) [@ufna](https://forums.unrealengine.com/u/ufna)\
**Post date:** [July 16, 2014, 6:48pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/4 "2014-07-16T18:48:36Z")

</div>

Nice work, man! 🙂

---

<div class="post-metadata">

**Author:** ![AlwysAnrchy](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AlwysAnrchy](https://forums.unrealengine.com/u/AlwysAnrchy)\
**Post date:** [July 16, 2014, 7:29pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/5 "2014-07-16T19:29:59Z")

</div>

Fantastic work Mikepote! That Material looks amazing. Keep up the great work

---

<div class="post-metadata">

**Author:** ![KRushin](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@KRushin](https://forums.unrealengine.com/u/KRushin)\
**Post date:** [July 16, 2014, 8:56pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/6 "2014-07-16T20:56:17Z")

</div>

very nice, I’d be interested in seeing how you did it!

---

<div class="post-metadata">

**Author:** ![ActivistMonkey](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ActivistMonkey](https://forums.unrealengine.com/u/ActivistMonkey)\
**Post date:** [July 17, 2014, 1:04am UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/7 "2014-07-17T01:04:42Z")

</div>

yes i would def. love to see the material on one amazing stuff.

---

<div class="post-metadata">

**Author:** ![scrcro](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/scrcro/32/1008648_2.png) [@scrcro](https://forums.unrealengine.com/u/scrcro)\
**Post date:** [July 17, 2014, 8:51am UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/8 "2014-07-17T08:51:39Z")

</div>

Beautiful.

---

<div class="post-metadata">

**Author:** ![Sitrec](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Sitrec](https://forums.unrealengine.com/u/Sitrec)\
**Post date:** [July 17, 2014, 9:03am UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/9 "2014-07-17T09:03:46Z")

</div>

Very cool, would love to see it used ingame.

---

<div class="post-metadata">

**Author:** ![lloadead](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@lloadead](https://forums.unrealengine.com/u/lloadead)\
**Post date:** [July 17, 2014, 1:31pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/10 "2014-07-17T13:31:45Z")

</div>

Nice work Mikepote, Really great!  
Would You Please share the final Material With us “For learning Purpose of course” ?

---

<div class="post-metadata">

**Author:** ![Mikepote](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mikepote](https://forums.unrealengine.com/u/Mikepote)\
**Post date:** [July 17, 2014, 5:51pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/11 "2014-07-17T17:51:36Z")

</div>

Sure!

Here’s the material as a .T3D file with all the non-standard textures I used, I’m not sure how you can import again after exporting it from the editor though?

And here’s what it looks like in-game:

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/9/3/59345ed63b6fa30aadac01521127ea666beb2a2a.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/d/e/7decac863bda026de8e5512535b19d76e50b8c9a.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/4/6/74639e45d1bbe2f4af82fa5ce184714bfeed0626.jpeg)

 ![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/b/1/db1bc1989cc9876ea9dbfc91bba44aa59d4ca8fe.jpeg)

---

<div class="post-metadata">

**Author:** ![lloadead](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@lloadead](https://forums.unrealengine.com/u/lloadead)\
**Post date:** [July 18, 2014, 11:44am UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/12 "2014-07-18T11:44:40Z")

</div>

> [@Mikepote;98543](#):
>
> Sure!
> 
> Here’s the material as a .T3D file with all the non-standard textures I used, I’m not sure how you can import again after exporting it from the editor though?
> 
> And here’s what it looks like in-game:
> 
> [http://i.imgur.com/lvRxHCT.jpg](http://i.imgur.com/lvRxHCT.jpg)
> 
> [http://i.imgur.com/lYNC8MJ.jpg](http://i.imgur.com/lYNC8MJ.jpg)
> 
> [http://i.imgur.com/NhevSS0.jpg](http://i.imgur.com/NhevSS0.jpg)
> 
> [http://i.imgur.com/P20qmln.jpg](http://i.imgur.com/P20qmln.jpg)

Thank you for your Kindness , but unfortunately when i import it nothing happens , can you please provide a .uasset files of your materials ? and Thanks Again 🙂

---

<div class="post-metadata">

**Author:** ![Mikepote](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mikepote](https://forums.unrealengine.com/u/Mikepote)\
**Post date:** [July 18, 2014, 6:54pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/13 "2014-07-18T18:54:21Z")

</div>

Okay, I’ve updated the zip file to include the .uasset file for the material. The textures you will have to import manually and hook up into the material once it’s imported.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_0df12f74](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_0df12f74](https://forums.unrealengine.com/u/anonymous_user_0df12f74)\
**Post date:** [July 18, 2014, 6:56pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/14 "2014-07-18T18:56:04Z")

</div>

Very cool! Thank you for ! 🙂

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_9af1a529](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_9af1a529](https://forums.unrealengine.com/u/anonymous_user_9af1a529)\
**Post date:** [July 18, 2014, 7:27pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/15 "2014-07-18T19:27:34Z")

</div>

That looks \*\*\*\* amazing. Can’t wait to get home and check it out!

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2793493e1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2793493e1](https://forums.unrealengine.com/u/anonymous_user_2793493e1)\
**Post date:** [July 19, 2014, 6:26am UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/16 "2014-07-19T06:26:15Z")

</div>

> [@Mikepote;99391](#):
>
> Okay, I’ve updated the zip file to include the .uasset file for the material. The textures you will have to import manually and hook up into the material once it’s imported.

Just Right Click in MasterMaterial on Content Browser, choose MIGRATE, and after choose a folder. Without the complete hierarchy we can´t understand where to put the textures.

---

<div class="post-metadata">

**Author:** ![lloadead](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@lloadead](https://forums.unrealengine.com/u/lloadead)\
**Post date:** [July 19, 2014, 2:43pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/17 "2014-07-19T14:43:01Z")

</div>

> [@;99582](#):
>
> Just Right Click in MasterMaterial on Content Browser, choose MIGRATE, and after choose a folder. Without the complete hierarchy we can´t understand where to put the textures.

Yeah me too i can’t figure out how to put the textures and i have problem “Error” :

 ![583ae2215dba135faee14a4e27ba1ef09e916360.jpeg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/8/3/583ae2215dba135faee14a4e27ba1ef09e916360.jpeg)  
Please help us ☹

---

<div class="post-metadata">

**Author:** ![Spectronaut](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/spectronaut/32/1018256_2.png) [@Spectronaut](https://forums.unrealengine.com/u/Spectronaut)\
**Post date:** [July 19, 2014, 11:39pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/18 "2014-07-19T23:39:59Z")

</div>

Very nice.

---

<div class="post-metadata">

**Author:** ![CharlestonS](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@CharlestonS](https://forums.unrealengine.com/u/CharlestonS)\
**Post date:** [July 19, 2014, 11:44pm UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/19 "2014-07-19T23:44:15Z")

</div>

If you have already migrated the textures they should stay linked in the node tree, if not you can manually link them by selecting the texture in the content browser then selecting that Texture Sample node in the material node tree then in the left pane (Details) scroll down to Material Expression Texture Base and for the Texture cick the little Left Arrow to use the texture you have selected in the content browser.

> [@lloadead;99857](#):
>
> Yeah me too i can’t figure out how to put the textures and i have problem “Error” :
> 
> ![583ae2215dba135faee14a4e27ba1ef09e916360.jpeg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/8/3/583ae2215dba135faee14a4e27ba1ef09e916360.jpeg)  
> Please help us ☹

---

<div class="post-metadata">

**Author:** ![Mikepote](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mikepote](https://forums.unrealengine.com/u/Mikepote)\
**Post date:** [July 20, 2014, 9:09am UTC](https://forums.unrealengine.com/t/shallow-ocean-shader/7704/20 "2014-07-20T09:09:27Z")

</div>

Ah okay, you need to put in T\_CubeMaps\_City01\_Envmap from the Elemental demo there.  
I’ll try package it up into a zip file using the migration method…

[Next page](https://forums.unrealengine.com/t/shallow-ocean-shader/7704.md?page=2)
