I am currently trying to simulate the look of rapids flowing into a calm basin. A solution that makes sense in my head, but which I struggle to implement, is to place a transparent plane with a faster, wavy, foamy material over my basic water plane where the river meets the basin. I made a simple illustration to explain things more clearly.
I can make it work when it comes to the foam/white water effect - however, I just can’t make the specular reflections of the waves show up unless, strangely enough, both planes are perfectly on top of each other, where the wave reflections are visible but, obviously, show heavy clipping.
As soon as I lift the wave/rapids plane just a smidge over the base water plane to avoid said clipping, its reflections disappear completely.
Here’s a screenshot of how the material appears in the material editor:
Here how it looks like when both planes are perfectly stacked. What is not visible in the screenshot is the strong clipping effect caused by the engine seemingly struggling to decide which object to render. Minus the clipping, this is the effect I want to achieve.
So yeah, I’ve been trying to work out a solution to deal with this. I’m also quite open if anyone has another simple solution to fake rapids flowing into a lake!
Nedds more info.
Did you make the materials? Are they engine stock but modified? Are they transparent (that would be a nono)?
Also, this could work visually from afar, but will always fail upclose.
The incoming rapids would displace the calm water - a wave sucks in before passing.
If you also need it upclose then you would need a single mesh/material - and it is possible, just grab the nodes that make the effect you want, shove them in there - same mat - and tie them up to only show when the single channel of a texture as the alpha.
Then make that texture a render target - then over time draw up that texture so it becomes white generating the effect you want.
If you refine and tween the leading edge of the 0/1 lerp change you should be able to achive some fairly realistic looks even up-close…
So the basic water material - the one underneath - comes from Waterline Pro.
I made the top material myself. It’s simply a surface material, blend mode translucent, lighting mode surface translucency volume. I just tiled a normal map with a wave texture on it, using a grayscale version of the same texture at different scales for the white water effect, and gave it motion with a panner.
I agree that up close it doesn’t work, but it’s really for a background effect.
Unfortunately, I didn’t quite follow the alternate suggestion you gave - I think it might be a bit too advanced for my level with unreal!
Well, no worries.
The problem at the core is the transparency - the engine doesn’t sort them right and offers no way for you to direct the priority (well check on that might be different with newer development).
If you make your materials non-transparent, they will sort like you expect.
The mask/transparency for them will look a little different ofc, but you have to make do with what the engine can do in this case…
Why don’t you add the waves and foam interaction right in the water material and you can control its intensity by adding camera position node or the actor node so you can determine at what distance your waves would start to appear, i hope i am getting the point across.
or maybe use the inbuilt water system which gives you lake and oceans etc, you can tweak the material settings and waves speeds and all of that.