Mārtiņš Upītis Profile picture
Sep 10, 2021 15 tweets 6 min read Read on X
Smooth transition from air to underwater in Blender(work in progress). I’ll do a thread because not often I see it done right in CG.
#b3d
I teach things like these in art college. I guide my students through the analytical process of dissecting the effects of physical lighting and materials.

So there are several concepts you have to understand that will let you create the water transition effect convincing. Image
First concept - we have to imagine that our Blender camera is actually a real camera. Camera has a sensor, lens assembly and most importantly - a waterproof housing.
(Image source - Outex) Image
In praxis, we can simplify the shape of the housing as a sphere around the centre (sensor) of the Blender camera. Image
Second concept - There are terms like ‘surface tension’ and ‘cohesion’, but for sake of simplicity, let’s just assume that water is ‘sticky’. It sticks to itself and tends to form a spherical shape. So at its borders, water will bend light like a lens. (Image source Getty Images) Image
So in Praxis we just don’t let water at it’s edges look flat. How I did it in the video example above? I made a new geometry just for the air/water transition. A thin cylinder slice worked well. Then using ‘shrinkwrap’ modifier, projected it to the water surface.
For ‘rounding the edges’ part, I blended real normals with up vector and ‘virtually’ bent it.
Third and last concept - understanding indices of refraction (IOR) between different mediums. It is probably most complex between the three, but rather important for proper ‘water look’.

Refractive Index between lens and water is different than that of lens and air. Image
Pro advice: search for real life references. In this case “split level photography” returned stuff I was looking for.
Don’t look for references in games or how others (like me) are ‘faking’ it 😅. Image
It looks like this in wireframe. The edge ‘fin’ cylinder is vertex parented to the Camera, so it does not rotate with it. The fin has two ‘shrinkwrap’ modifiers influencing upper and lower edges separately. That way I can control the thickness. ImageImage
Hole in the water surface is shader based, calculated based of distance from Camera object. ImageImage
Combining the hole and the ‘fin’, it looks like this. Image
Even though the water surface and edge ‘fin’ are two separate objects, we can make it look like one with normal ‘bending’. I included water surface shader node tree (2nd image) and edge ‘fin’ node tree (3rd).
Note: I disabled transparency for clarity. ImageImageImage
I guess I have covered the basics regarding the transition. Seeing that the thread has gained some popularity, I will do the same for other water rendering topics.
Next thread will be about the water surface, where IOR will play significant role.

And to conclude the topic and open the discussion. Have you seen the water surface transition used in any games?
I know @Unigine does it like this (screenshot from water tech video) Image

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Mārtiņš Upītis

Mārtiņš Upītis Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @_martinsh

Feb 9, 2022
exercise - real anisotropic reflections in Eevee render in #blender.

In theory it means that surface has ‘controlled’ scratches going in same general direction.

My first tests turned out quite pretty, although requires multiple render samples unlike the analytic approach. ImageImageImageImage
With Voronoi texture you can make quite convincing scratching. Each cell gives you ‘position’ data that you can shape into a line and rotate via any data value - texture or vector.

Here is a regular voronoi grid, lines are scaled by a photo and rotated by Perlin noise. Image
goal for this experiment is again automotive shader related - I want to achieve realistic microscratching on shiny surfaces.

This is my first test. I am not entirely satisfied, but I am getting there eventually. Image
Read 8 tweets
Jan 14, 2022
Let’s consider the previous thread a ‘teaser’ for this tweet sized introduction into retroreflectivity in CG.

I’ll explain what it is and how to do it yourself in #blender

As before - I will divide it in ‘Theory’ and ‘Praxis’ parts.

So here we go..
🧵
Just a disclaimer. This will be no science class.
In my side job as a Blender teacher in art college, I convert concepts that are difficult to grasp to simpler analogies and I leave out the hardcore stuff (So I don’t scare away my ‘kids’)

That’s a job for universities.
Theory is simple:

Retroreflectors reflect majority of received light directly back to its source.

How does it differ from specular reflection?

Specular reflection directs only a small portion of light that bounces back from the surface normal facing the source. Image
Read 23 tweets
Jan 4, 2022
I'm now hooked on developing physical automotive materials in Eevee #Blender3d

This time - suede (Alcantara) with varying fiber direction and fingerprint-y anodized aluminum.
The suede material is fully procedural (using Blender built-in Noise) It will look even nicer with real Alcantara surface texture. Fiber flow is again a larger noise color texture, converted to a normal map. ImageImageImage
steering wheel 3D model by Gurdeep Panesar
artstation.com/swedgedesign
Read 10 tweets
Dec 23, 2021
Last day before I take my time off work and I spent it tinkering with car headlights again!
This time I am exploring polarised light and thin-film interference on a transparent body in Blender.

Thank you @KarolMiklas for car model! Beautiful work as always 🙏

Follow the 🧵👇 ImageImageImageImage
Polarised light and Thin-film interference are not the same in terms of physics. One is caused by injection moulding of the plastic, other - by a very thin layer of material on the surface of another material.
Both offer similar looks, so I use the same technique to model it. Image
Here are two real-world examples. ‘Colorisation’ on the headlights are caused by polarisation while on windshield - by a defrosting coating. Most people, including me, mixes these, so for an artist like me, a single approach to tackle both problems, is working just fine! 👌 ImageImage
Read 19 tweets
Dec 10, 2021
Physically-based car headlights in Blender. This method is made for Eevee because refraction and reflections in a single material do not interact nicely.
Here is a breakdown of the classic reflector/refractor headlights. If you want to know more, follow the🧵
#b3d
Let's start with the reflector - the shiny chrome part behind the glass.
Modelling it accurately is rather important, especially if you plan to have the headlight turned on. @KarolMiklas has done sublime work on those! Even for a low-poly car, the normals are silky smooth!
And here's why an accurate model with a nice topology is important. I put a 50-watt "bulb" where it should be in reality. Viewed off-axis, the headlight barely is shining, but once I look head-on, the light is very concentrated. Really cool to see it work in Blender so well!
Read 9 tweets
Sep 24, 2021
This little detail goes a long way. Let’s see if you can spot it!
Another water rendering related thread below.
#b3d
‘Contact line’ or ‘meniscus’ as some of you wrote (I just did not know how to call it) is again the same effect I discussed previously about the bent edge of water surface due physics. In this case the border is now touching a half-submerged object not the lens. Image
Quite often in games we see contact ‘foam’ to show when object is touching water. It works best for stylised water, or larger objects in stormy sea, but smaller objects in still water requires something more subtle. ImageImage
Read 8 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(