Masked water.tgd (Massive render time chopper)

Started by dandelO, January 31, 2010, 10:59:55 PM

Previous topic - Next topic

FrankB


Henry Blewer

http://flickr.com/photos/njeneb/
Forget Tuesday; It's just Monday spelled with a T

Oshyan


Goms

First: Sorry for re-opening, but i think in this case its ok.

There is a way to do this depending on the terrain.
If you combine your Terrain, made black with a distribution shader, and a power fractal that has (maybe, if you the water is not rendered where it should be) some displacement offset and is all white with a merge shader set to highest and use this as opacity input for a default shader, you will get exactly this. :)

without this in 2:23


with this in in 1:34


the nodes:



and the TGD is attached. :)
Quote from: FrankB
you're never going to finish this image ;-)

choronr


AndyWelder

Thanks a lot for this great contribution, DandelO. Works like a charm.
I would like to ad a caveat however: Keep in mind the .TGD originally has only 2 render threads enabled and the subdivision cache is limited to 200 MB. If you have a quad core system you might want to enable 4 threads and raise the subdivision cache to 400MB.
"Ik rotzooi maar wat aan" Karel Appel

dandelO

Thanks, Andy. I know, sorry about that, it's a very good point.
Lots of my shared files actually will be like that. They'll mostly be set for whatever machine I'd been using at the time, which has been usually a single or dual core with not much RAM.
I'm rewriting many of my uploads for my own site, in time. I'll be sure to right the SD cache and open up the max threads field in my uploads in future.
I noticed this myself before when I had to download an early voronoi caustic file I'd shared, I was on a higher spec pc and that file was saved to use 1 thread, I noted it as something I need to fix, when I update the files, soon...

Cheers, man! :)

Floating.Point

Firstly thankyou so much for this excellent resource!

I would like to confirm that this does indeed work with the default lake object.

Also, I have noticed a significant issue with using a plane instead of a lake object...
Im not sure the technical reasons for the obvious "reduction of niceness"

But here is an example of using the same waterplane masking method on a lake object, and a plane object...
Notice how yucky the transparency is, with that hard edge... also the noise and general quality is not as nice.



But it doesn't really matter.... because the masking technique works on the lake object anyways!
Cheers!

dandelO

Uncheck 'cast shadows' on the plane! ;) If you check the settings of a default lake, you'll see that shadow casting is unchecked by default. That's all it is.

:)


neuspadrin

#26
Hey, long time no forum/terragening, but I was bored today taking a break from school work and was looking at this (and playing with new update) and then expanded on this clip a little.

Basically taking this clip, then extending the idea by allowing it to follow terrain (like a river flowing down a mountain side, all easily painted).

I used a plane object instead of a lake (I believe this is the same method dandelO used to make a waterfall), and sent the computed terrain as input into the water area mask.  

I created a very basic distribution shader that was blended by the painted shader, which then attaches to a displacement shader right before compute terrain, which has a negative multiplier allowing it to make a ditch.

That distribution shader also goes into the displacement of the "water surface - plug in here" layer, which then has a displacement multiplier of positive 4 in this image I believe.


Anyways, just thought I would share that quick modification possible to turn this clip into a very nice paintable river for down hills/rapids/whatever you wish.

Heres a quick scene I whipped up to demonstrate it, and a screenshot of the relevant node network.

Henry Blewer

With just a little extra work on the water shading, rough water could be done well using this, I believe.
http://flickr.com/photos/njeneb/
Forget Tuesday; It's just Monday spelled with a T

Dune

This is the way I did downhill rivers as well, but the main problem is that the displacement used on the water base will have its 'sideways irregularities'. It will kind of follow the sideways curve of the mountain if you don't pick your POV carefully. For a real rough river it works though, especially if you throw some rocks into the riverbed and some foam (I use two layers, one overall, and one for steeper water).

max_thehitman


Very cool ideas and great info too! Thanks for sharing your expertise on this matter.
I will keep this as a tutorial for future reference.
THANKS EVERYONE! Great art you create!

Cheers
MAX