Here comes the Ghibli style sea tutorial 2.0! Kind like the last version we have shared, this is still a beginner-friendly tutorial that requires barely no modeling and painting skills. Also, the visual effect will still be created with the Shader Editor on a plane.
Compared to the last tutorial, the new sea is made of two layers: foam above and sea water below. So let’s create the foam layer first.
The Foam Layer
Like we mentioned in the last tutorial, please make sure you have enabled Blender’s Node Wrangler add-on, delete all objects in the scene before we get started.
First, click Add (Shift + A) add a plane, enlarge it appropriately and press Ctrl + A to apply all All Transforms. And then switch to Shading workspace, select the plane and add a new material to it.
Delete the Principled PSDF and add an Emission node. In order to create the foam effect, we need to use a combination of two Voronoi Textures. Let's first switch the dimension of the to two Voronoi Textures 2D, and keep one of the Feature Output to F1, and change the other to Smooth F1. By comparing the differences between these two feature outputs, you will find the F1 mode has a clear boundary.
Now if you connect these two nodes with a node that perform Subtract operation, you will get the basic shape of the foam we need.
And to have detailed adjustment of the effect, let's add a Color Ramp node first and change the color, scale, and smoothness accordingly.
Give both the Voronoi Textures a mapping to facilitate later texture effect adjustment by click the node and press Ctrl + T. If we simply add animation effects to the Location attribute of the Mapping node, it’s not hard to find that this is inconsistent with the actual changes in the sea. And what we actually need, is more irregular wave motion effect.
Therefore, in order to restore the effect of seawater flow, let's first separate the vector of the Y axis (you can also choose the X axis according to your preference), and then combine the Musgrave Texture node to achieve the effect of irregular flow in one direction.
If the distortion of Musgrave Texture is too severe, it can be optimized by reducing the detail parameters.
And now if you animate the Musgrave Texture (with "#frame/number" drive) in the Mapping node, the effect will be much better.
In order to make the sea layer more visible, we need to add a Mix Shader and a Transparent BSDF to the foam layer, and use the color of Color Ramp node to control the of Mix Shader, like the image show above.
Remember to change the Blender Mode of Mix Shader to Alpha Blend. In addition, enable the Ambient Occlusion and Bloom in Render Properties to simulate the effect of reflections in sunlight.
The Sea Water Layer
Select the foam lay and press Shift + D to make a copy, move down a little and click copy to isolate the material. Delete the nodes that we don’t need (or you can copy in the plane before adding these two nodes).
Then adjust the color of the sea layer.
And now play the animation, you did it, again!
XRender | Fast · Affordable · Reliable