How to make a river with an image shader??? Newbie question

Started by Terrafied, January 19, 2010, 08:17:12 PM

Previous topic - Next topic

Terrafied

 ???Ok, Ok, I know it's been asked before but I can't figure it out. How do I take my black and white image from Photoshop and use it to displace the fractal ground in order to add water and have a river? Can I do this with a power fractal or do I have to use a heightfield map. I'm not using GIS or DEM data. I just need a river. I've found a few tuts online but nothing that states it as plain as possible for the newbies. If someone could point me in the right direction that would be great. I'm also on a Mac if that helps.

Here is an image of my setup so far and the image map I want to use as a river.

FrankB

before the compute terrain, you add a displacement shader. Into the child port of the displacement shader, you add an image map shader (to load and project your river).
You would use projection on x/z and remember to scale the image, maybe like 5000 / 5000 or so. I don't know you'll have to try this out.
Then, in the displacement shader, you would set the displacement multiplier to - say - minus 20. THis is how deep your river will be, where the river mask is pure white.

And that's it.

Regards,
Frank

Dune

You can also use the image map shader itself for the displacement. And to find out where your river is, temporarily attach it to a last surface shader into the color input, it'll be a white river. I always use this method with a 'test surface shader' to visualize all sorts of maps and power fractals.

---Dune

schmeerlap

I hope I realise I don't exist before I apparently die.

Terrafied

Hey guys,

Thank you, thank you, thank you. These are all great suggestions. I will try them out this evening and let you know how it goes.
This forum is awesome...because of the people of course.

Thanks again!