Planetside Software Forums

General => Terragen Discussion => Topic started by: Mohawk20 on February 04, 2009, 04:31:49 AM

Title: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on February 04, 2009, 04:31:49 AM
Since the Ashundar Image of the Week contest theme is Crystal Clear, I was inspired to create a scene where the camera looks through a waterfall (from behind it of course). After the render completed I thought I made an obvious mistake thinking this would be possible, because the sky rendered black through the water (see first image below).

But then I did some post editing, and I found out the sky did render, it was just very dark (see second image below). This leads me to believe that if the Decay Distance is set higher than the slider's max (1000), the sky might become visible in the render without post work.
Did anyone else know about this?
Title: Re: Vertical water plane
Post by: JimB on February 04, 2009, 05:40:37 AM
Are the brighter white cloudy looking things actually clouds in the sky? If so, it seems odd that they'd render at almost expected brightness (probably half, but nowhere near as dark as the sky).

Are you sure it's not colour filtering through the water density causing the sky's atmospheric blue colour to darken, because of the greeny yellow default setting? Have you tried making the subsurface colour neutral grey?
Title: Re: Vertical water plane
Post by: PG on February 04, 2009, 06:02:30 AM
I didn't know you make the lake object vertical :D
Title: Re: Vertical water plane
Post by: Mohawk20 on February 04, 2009, 06:36:08 AM
The subsurface colour is a more blue tint than the default. But after rendering a few other tests I see that this effect might be some sort of reflection.

The sky does render though, if you set the distance high enough, but it doesn't look like this (yet).
I'll upload my next result when the render finishes.
Title: Re: Vertical water plane
Post by: Mohawk20 on February 04, 2009, 09:15:33 AM
Below images have very high Decay Distance. The first one has a value of 1e+008, the second one 1e+010.
The last one seems to do the trick.

So although the initial effect that lead me to this was probably only a reflection, it is actually possible with the right settings.
Now to get a more realistic shape to it...
Title: Re: Vertical water plane
Post by: old_blaggard on February 04, 2009, 10:54:27 AM
Cool!
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 04, 2009, 02:58:46 PM
Quote from: old_blaggard on February 04, 2009, 10:54:27 AM
Cool!
Yes, as it is natural mountain water  ;D ;)

Below image has the plane resized a bit and I added a power fractal with billows noise, stretched to 10 on the y axis. It took 4,5 hours to render, but it actually does look pretty good... (sometimes the software still amazes me).
The Decay Distance in this one is 1e+009, which seems to be just as good as 1e+010.

So, everyone, get those waterfall scenes started!!
Title: Re: Vertical water plane -> Waterfall
Post by: old_blaggard on February 04, 2009, 03:01:14 PM
Here's an idea - try feeding the water shader into the input port of a default shader, and then using a tweaked power fractal as an opacity function. You should be able to get trails of water suspended in space, which will look more realistic. You could also integrate some clouds to act as mist, and you would have an incredibly convincing setup.
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 04, 2009, 03:03:01 PM
Which is a very good idea. You should get started on it  ;)

I'll see what I can make of it...
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 05, 2009, 02:13:08 PM
Those clouds aren't a problem, but feeding the water shader through the default shader gave some problems, specially in combination with that opacity function.

It seems that the parts that stay opaque also stay black/dark in stead of clear/watery. And controlling the opacity is a lot harder than I hoped.


Are you having any luck with it OB?
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 05, 2009, 02:22:31 PM
Cool work so far Mohawk :)
I guess you're using a plane-primitive with a watershader applied as surfaceshader?

The problem with the opacity might be due to TG2 still not being able to read grayscales from opacity. So its either fully opaque or fully transparent.
I can be mistaken, but I think this hasn't been fixed already.

Martin
Title: Re: Vertical water plane -> Waterfall
Post by: old_blaggard on February 05, 2009, 03:06:00 PM
I haven't tried it yet and I probably won't have time to for quite a while.

Quote from: Tangled-Universe on February 05, 2009, 02:22:31 PM
Cool work so far Mohawk :)
I guess you're using a plane-primitive with a watershader applied as surfaceshader?

The problem with the opacity might be due to TG2 still not being able to read grayscales from opacity. So its either fully opaque or fully transparent.
I can be mistaken, but I think this hasn't been fixed already.

Martin

That's true, but all you need are black and white: black for no water, white for water. The problem is that is appears that the default shader is not allowing the transparency effect from the water shader to get through. I'm not exactly clear on how opacity is passed along the network, so perhaps feeding the default shader into the water shader instead of the other way around would preserve the transparency while allowing the opacity to do its thing.
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 05, 2009, 03:14:56 PM
I don't need grayscale, the black and white of a powerfractal can still make some pieces invisible while the rest stays visible (see below).
The problem is that using a default shader to apply the opacity effect kills the water effect, as you can see...


I'll try rearranging the nodes, (something I thought of before reading OB's post  ;)
If the transparency doesn't come through the opacity, let's hope it works the other way around.

If it does, we have a winner!
(I'll be waiting for that nobel prize  ;) 8))
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 05, 2009, 03:22:51 PM
Quote from: Mohawk20 on February 05, 2009, 03:14:56 PM
I don't need grayscale, the black and white of a powerfractal can still make some pieces invisible while the rest stays visible (see below).
The problem is that using a default shader to apply the opacity effect kills the water effect, as you can see...

Ok, you don't need grayscale, but since grayscales doesn't work it also implies that the opacity-function still isn't working properly and therefore could still be the reason of your problem.
You're probably right that it is something else but I would never rule it out though.

Quote from: Mohawk20 on February 05, 2009, 03:14:56 PM
I'll try rearranging the nodes, (something I thought of before reading OB's post  ;)
If the transparency doesn't come through the opacity, let's hope it works the other way around.

If it does, we have a winner!
(I'll be waiting for that nobel prize  ;) 8))

Can you show me how you set this up? I might be able to help?
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 05, 2009, 03:33:58 PM
It's pretty easy:
Create a plane, use settings: edge vector A= 0-1-0 , and Edge vector B= 1-0-1
Use any other size settings you like.

Go into the internal network and create a water shader and change Decay Distance to a value of 1e+009.
Plug the water shader into the plane's surface shader input
Create a powerfractal and plug it into the water shaders input.
Use a relatively small scale and perlin-billows as noise. Stretch the noise to 10 on the y-axis.

For opacity, use the already created default shader that came with the plane object. Copy the powerfractal and increase the size settings a bit. plug that into the opacity function input of the default shader.
Now, try to find out how to attach the default shader so everything works...
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 05, 2009, 03:38:34 PM
Well...isn't the solution quite simple?

Create a Distribution Shader V4, add the watershader with powerfractal as a child layer to the distribution shader. Then plug the powerfractal for the opacity into the blendshader and there you go. You even then have grayscales functioning :)
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 05, 2009, 04:15:17 PM
That's the reason why I post my problem on these forums. There's always someone with a fresh view on the case.
I'm gonna try that right away...

On the other hand..
If you replace opacity with blending you have a problem.
What disappeared when using opacity just remains black if using blending.
So instead of erasing pieces of waterfall, we would be adding pieces of simple plane into the waterfall.
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 05, 2009, 04:39:49 PM
Haha, well that is just how you look at blending :)
In photoshop you can add a layer mask set to "reveal all" or "hide all"...so you can either mask to reveal stuff or to hide it. It's just how you look at it, but you're right :)
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 05, 2009, 05:21:44 PM
Well, TG isn't PhotoShop, and I was talking TG... (I know PhotoShop can blend better).
Even though I don't expect it to work, I'm still rendering with the setup you suggested.
Let's see what happens.

If it doesn't work, does anyone else have any ideas?
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 05, 2009, 05:25:01 PM
Of course, I just meant to explain different ways of thinking :)
Looking forward to see the result. Can't think so fast about a reason why it won't work. It offers everything you need.
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 06, 2009, 05:22:29 AM
I suggest you try for yourself, because the result I get is nothing to write home about...
See below. The part circled in red is different, because of the blending shader, but it's still a piece of plane, it should be a piece of sky...

I attached the tgd, so you can take a look for yourself..
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 06, 2009, 07:30:44 AM
Thanks Mo, I'll take a look at it as soon as I'm home and have time.

Martin

PS., cool dutch translation :) did you ever read the book "I always get my sin?" :)
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 06, 2009, 06:29:01 PM
Any ideas yet?
Below is my last render.
Took a while to get the clouds just right.

It will be the last of this project unless anyone can figure out that opacity thing...
Title: Re: Vertical water plane -> Waterfall
Post by: rcallicotte on February 07, 2009, 11:14:22 AM
It's still looks pretty good.
Title: Re: Vertical water plane -> Waterfall
Post by: Tangled-Universe on February 07, 2009, 11:21:51 AM
Quote from: Mohawk20 on February 06, 2009, 06:29:01 PM
Any ideas yet?
Below is my last render.
Took a while to get the clouds just right.

It will be the last of this project unless anyone can figure out that opacity thing...

I haven't had any time yet to check this out Mohawk, sorry.
I certainly will.
First I have to finish some renderingstuff and tutorial-writing, then install my new hard-drive and then I might be able to give it a go :)

Martin
Title: Re: Vertical water plane -> Waterfall
Post by: j meyer on February 07, 2009, 01:26:51 PM
Hi,
like that?
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 07, 2009, 01:42:37 PM
Hmmm, nice orange...  ;)

Yes, like that.
I'll take a look at it.
The opacity function should be bigger though, you'd want the lack of water mostly along the edges...
Title: Re: Vertical water plane -> Waterfall
Post by: PG on February 07, 2009, 01:52:47 PM
If there's a way to rotate the distribution shader you could have two facing opposite directions.
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 07, 2009, 02:46:02 PM
It would be nice to have a two-sided waterfall, but most of the time you only render one side anyway...
Title: Re: Vertical water plane -> Waterfall
Post by: PG on February 07, 2009, 04:02:14 PM
No I mean to get the effect of water density dropoff to the edges. use two distribution shaders, facing the same way but rotated so that one performs a dropoff to the left and the other performs the dropoff to the right. maybe I'm thinking of the distance shader applied to a default shader.
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 07, 2009, 05:48:38 PM
Could be done with a painted shader (stupid me, why didn't I think of that before?).
Just paint on the plane, make the middle white with drop-off to the edges, attach as blending, invert blending..

But where to apply the blending? At the opacity function powerfractal, it doesn't work.
Adding a second distribution shader for the default shader, applying the painted shader as distribution to that and plugging that as input into the first distribution shader doesn't help either.
Title: Re: Vertical water plane -> Waterfall
Post by: Mohawk20 on February 10, 2009, 03:58:10 PM
Managed to figure it out!
See below for the result, opacity only applied to the sides of the plane.
I made a screen shot to show what the internal network of the plane object looks like.

Next I will add a translate shader and do a little animation of the water flowing down...

Title: Re: Vertical water plane -> Waterfall
Post by: rcallicotte on February 10, 2009, 11:09:55 PM
Thanks for sharing your work on this!
Title: Re: Vertical water plane -> Waterfall
Post by: old_blaggard on February 10, 2009, 11:26:50 PM
Very nice work! I'm glad that this all came together.
Title: Re: Vertical water plane -> Waterfall
Post by: dandelO on February 11, 2009, 04:32:20 PM
Cool. It's nearly the same setup as my masked waterplane river.tgd plane object, the water is only drawn where the painted shader(or its inverse) describes. Pretty much exactly the same except I use a surface layer instead of a distribution shader at the end.
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on February 13, 2009, 06:26:42 AM
Great minds think alike  :o
I added a transform shader that translates the y value from 0 to -50 in 100 frames. Copied it and placed after both power fractals.
The result is I think as good as it gets. Not extremely realistic, but then it isn't a particle system, so realistic simulation should not be expected...
This is the link to the anim: Download here (http://mikel.hbyte.net/Files/Waterfall.avi).
It's an avi, 8 Mb in size, with with Xvid video and uncompressed wav audio.

Let me know what you think...
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on December 13, 2019, 04:23:34 PM
So it's been almost 11 years since I started this thread...!


Meanwhile I got married (2012) and had less time for Terragen.

Still, sometimes I have a moment to spend on my hobby, and I try stuff.

So in the last couple of years i've tried to make something realistic out of this...



I think I'm getting there.
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on December 13, 2019, 04:26:07 PM
Too many at once ... ::)
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on December 13, 2019, 04:27:17 PM
And more.
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on December 13, 2019, 04:33:52 PM
And finally:
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Oshyan on December 13, 2019, 05:18:03 PM
Some really cool results! I agree, you're definitely getting close to realistic.

The reason you can't post more images per-post is that your jpg's are *huge*. Much bigger than they should need to be to have good quality. What are you using to output/compress to JPG?

Btw, congrats on getting married! :)

- Oshyan
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Mohawk20 on December 13, 2019, 05:29:06 PM
The waterfall is basically just a plane with water texture surrounded by 3 kinds of clouds, tweaked to infinity.


I know about the file size...
I output from Photoshop cs6 at highest quality.

And thanks, nearly 8 years now. Time flies!
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Oshyan on December 13, 2019, 06:34:16 PM
Photoshop's "highest quality" is absolutely needlessly wasteful for web use. Use Save for Web and a quality of 60-80 and you'll have extremely high quality with lower file size.

- Oshyan
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: WAS on December 13, 2019, 10:52:37 PM
It definitely looks really convincing from a distance. Great work here. Cool to see waterfalls revisited with fresh eyes. I don't think I've ever done a waterfall in TG. I think I recall questioning about it ages ago. 

One suggestion would be to use a larger scale PF which is vertically stretched (maybe voronoi ridges) and use that for a breakup on the clouds. A similar one without the stretch would help breakup water plume at the base with more variety.
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: Dune on December 14, 2019, 03:28:19 AM
I thought you'd vanished forever Mohawk. Good to see you back and married and all. Congratulations! And nice waterfalls, really very realistic.
Title: Re: Vertical water plane -> Waterfall (+animation)
Post by: bobbystahr on December 15, 2019, 03:36:39 PM
Quote from: Dune on December 14, 2019, 03:28:19 AMI thought you'd vanished forever Mohawk. Good to see you back and married and all. Congratulations! And nice waterfalls, really very realistic.
Echo this...with my added congrats on the marriage.