Planetside Software Forums

General => Terragen Discussion => Topic started by: Zylot on August 27, 2009, 03:51:39 PM

Title: Suggestion: Blend Shaders for Displacement Shaders
Post by: Zylot on August 27, 2009, 03:51:39 PM
Hey guys, just some input.  I got some displacement shader plugged into a bunch of functions doing some pretty cool stuff.  I just don't want that cool stuff creeping up the mountains in the background.  Unfortunately, I can't help but notice that there's no way to blend displacement shaders via masks or anything, leaving me trying to find a wacky workaround.

So, just sayin'

Displacement, blend by shader, together one day.
Title: Re: Suggestion: Blend Shaders for Displacement Shaders
Post by: Volker Harun on August 27, 2009, 03:56:55 PM
You can use that Surface layer for terrain-displacements. Just turn off colour and plug into the displacment tab your function.
Hard Blending with the blending shader or softer shading with fractal breakup are possible.

Of course no need to tell you, that the altitude and slope constraints will not work on top of the first compute terrain node ;)

Volker
Title: Re: Suggestion: Blend Shaders for Displacement Shaders
Post by: N810 on August 27, 2009, 03:57:19 PM
Have you tried the paint shader yet ?
Title: Re: Suggestion: Blend Shaders for Displacement Shaders
Post by: Zylot on August 27, 2009, 04:02:57 PM
Volker, yeah that's the plan, but I'd rather just be able to use displacement shaders for their intended purpose.  Right now, he seems a bit underwhelming due to the limited scope of it's use.

N810, if I used that, there's still no place to plug it into the displacement shader.
Title: Re: Suggestion: Blend Shaders for Displacement Shaders
Post by: Tangled-Universe on August 27, 2009, 05:11:47 PM
Quote from: Zylot on August 27, 2009, 03:51:39 PM
...I just don't want that cool stuff creeping up the mountains in the background...

You can do this by using a distance-shader.
Default setting is a black -> white gradient from 0m to 10000m from the camera.
If you invert the distances you will have your displacements 100% at the camera's position and then slowly fading out over the distance of 10000m.

Martin
Title: Re: Suggestion: Blend Shaders for Displacement Shaders
Post by: Zylot on August 28, 2009, 08:40:30 AM
TU: That would work if it were (nearly) any other shader, but the displacement shader has no blend input, which is what my suggestion is. 
Title: Re: Suggestion: Blend Shaders for Displacement Shaders
Post by: Matt on August 29, 2009, 06:11:51 AM
If you don't want to use the Surface Layer as your displacement shader, you can still blend displacements directly by simply multiplying the displacement function by whatever shader or function you want (i.e. use a Multiply Scalar node). That's all that the blend shader option would do, if it were implemented in the Displacement Shader.

Matt