Unity fluid example discussion

I’ve been working on how to make comparisons that are close to real water, but I’ve never been able to get the effect I want.
Like this


shuiq48

I want to write a shader to simulate the effect of water . It’s so hard for me.

My English is poor, Hope you don’t mind

5 Likes

Just a headsup. I’m not able to access that site. Just tells me it’s a broken url.

It’s not a site,That was my fault. It automatically generated the connection.

Right, so water reflects and refracts, so ideally to be able to properly see it, you want some detail in the background.

Water also isn’t that blue.
The fresnel you are using looks alright, but try and use it to evaluate more then only colour.
Reflection and refraction of your surface is going to change depending on view angle.

1 Like

I’m guessing that example isn’t yours and that’s the effect your trying to achieve?

Looking at it it looks like vertex shaders using a simulation baked from Houdini using the latest game shelf tools, (something ive been doing myself and achieved but in Unreal rather than unity, so give that a google or go check the latest Houdini games videos on the Go procedural vimeo page)

Yep. That’s a vertexshader if I ever saw one. Based on the water behaviour I’m even wagering that it’s based of Varomix’s flip tutorial.

Thank you for your advice. I made some improvements

Ahhh apologies I thought you were asking how to achieve such an effect not asking for shader crit/comments! (Nice work :))

Looking loads better to me, would be helpful to see some other angles / different lighting to perhaps give more specific crit,

Water shading is suuuuper tricky because there’s really no one-size-fits-all solution. Whatever works for oceans most likely won’t work for rivers, and whatever works for rivers rarely works for puddles, etc etc. I would suggest that you really think about the mass of the effect you’re trying to make, and find some real-life reference that accurately matches that.

The other thing is lighting - even the best water shader will look flat in a gray environment. I strongly recommend doing your look-dev in a number of different lighting environments, as close as possible to the final game situation, to make sure that it holds up!

1 Like

Thank you for your advice so much,I’ll try it.