Author Topic: Redirect Shader Idea  (Read 248 times)

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Redirect Shader Idea
« on: November 15, 2018, 11:28:34 PM »
It would be cool if this shader had the ability to redirect colour space rather than also displacement. A mode to switch, or checkboxes like the merge shader.

Cause the only way to redirect textures is with displacement, or by adding displacement unless you use some sort of shader to strip the redirect shader of displacement like a colour to vector or something. But this leaves redundant calculation behind.

Than you come to something like clouds, where when you redirect cloud fractals, it renders the colour to a solid grayscale map, so you have to use the redirect as the input to a warp shader, which creates a totally different effect.
Art can be a window into the soul

Offline Dune

  • Terragen Alpha Tester (Win)
  • ***
  • Posts: 14435
    • www.ulco-art.nl
Re: Redirect Shader Idea
« Reply #1 on: November 16, 2018, 04:26:24 AM »
That's what the vector displacement shader is for.

Offline Matt

  • Planetside Staff
  • *
  • Posts: 3392
  • I'm the crazy one
Re: Redirect Shader Idea
« Reply #2 on: November 16, 2018, 04:30:10 AM »
I don't know what you mean by redirecting colour. Displacement has a direction, so that direction can be changed (redirected). Colour does not have direction. Can you describe it some other way?
Just because milk is white doesn't mean that clouds are made of milk.

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Re: Redirect Shader Idea
« Reply #3 on: November 16, 2018, 04:43:13 AM »
That's what the vector displacement shader is for.

Honestly, you've mentioned this a lot Ulco, and I'm not sure that I understand your usage, as using it (for me) as a warper creates a lean on +X as it expect vector input.

I don't know what you mean by redirecting colour. Displacement has a direction, so that direction can be changed (redirected). Colour does not have direction. Can you describe it some other way?

Hmm... Scalar's like you've explained before have Y position. I often use this for texturing, actually almost all the time, and sometimes I want to warp just this effect applied to surfaces without adding displacement, or warping displacement.

For example, when I use a "meta-layer" in my cloud setups, using a surface shader, I can use the redirect shader to simulate "altitude offset". However, for some reason, the output has no detail. If I use that same redirect into a warp input shader I do get detail, but that detail is "warped" via vertical displacement which is a whole other effect.

So... maybe I'm thinking more a Y Scalar variation redirection. Pushing it up and down.
« Last Edit: November 16, 2018, 04:45:03 AM by WASasquatch »
Art can be a window into the soul

Offline Matt

  • Planetside Staff
  • *
  • Posts: 3392
  • I'm the crazy one
Re: Redirect Shader Idea
« Reply #4 on: November 16, 2018, 04:49:34 AM »
Do you want to warp a colour shader in the X and/or Z directions? If you're using a Warp Input Shader or Warp Merge Shader you can warp just the specific thing you want to warp. The X and Z direction comes from using a Redirect Shader's X and Z inputs. I think you probably know how this works already, seeing some of your other setups. So I'm not really following what the question is.
Just because milk is white doesn't mean that clouds are made of milk.

Offline Matt

  • Planetside Staff
  • *
  • Posts: 3392
  • I'm the crazy one
Re: Redirect Shader Idea
« Reply #5 on: November 16, 2018, 04:51:55 AM »
Do you want to use a colour or scalar as the warper, instead of a displacement shader?
Just because milk is white doesn't mean that clouds are made of milk.

Offline Dune

  • Terragen Alpha Tester (Win)
  • ***
  • Posts: 14435
    • www.ulco-art.nl
Re: Redirect Shader Idea
« Reply #6 on: November 16, 2018, 05:01:48 AM »
No lean, just a shift. I use it like this, no warper.

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Re: Redirect Shader Idea
« Reply #7 on: November 16, 2018, 05:09:17 AM »
I think I'm mistaking the difference between tolerance with just a redirect, and that redirect as a warper fed into the warp input. The Warp input method has a lot more warping going on (so breaking up the clouds I'm applying too) as apposed to the redirect alone, but no detail.

Take these two examples with same redirect. Second one is the redirect shader fed into a warp input and into the colour function (to rid displacement).

And if you look at the ground in the warp version, that effect is applied to the clouds detail, which, well, destroys the cloud effect.

---

In summary, I just want to push the same detail (of a scalar on Y) present up and down by the intensity of either displacement/scalar, without warping.
« Last Edit: November 16, 2018, 05:11:15 AM by WASasquatch »
Art can be a window into the soul

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Re: Redirect Shader Idea
« Reply #8 on: November 16, 2018, 05:16:20 AM »
No lean, just a shift. I use it like this, no warper.

Oh that's nifty, but like the redirect, the colour effect is gone when piped into colour input or reduced to colour, so it either applies displacement or no effect. Definitely handy for some things I've wanted to do, though.
Art can be a window into the soul

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Re: Redirect Shader Idea
« Reply #9 on: November 16, 2018, 05:21:12 AM »
Annnd additionally, this 2D preview of my cloud density fractal may demonstrate the warping of the cloud shapes the best, just to achieve shifting the Y level.

Basically when you have a totally smooth perlin to create Asperatis swells in altitude, it creates circular warping (I'm sure you're familiar).
« Last Edit: November 16, 2018, 05:23:37 AM by WASasquatch »
Art can be a window into the soul

Offline Dune

  • Terragen Alpha Tester (Win)
  • ***
  • Posts: 14435
    • www.ulco-art.nl
Re: Redirect Shader Idea
« Reply #10 on: November 16, 2018, 06:24:09 AM »
Is something like this what you need?

Offline Tangled-Universe

  • Terrevangelist
  • *
  • Posts: 6183
    • CGScenery.com - Terragen Tutorials!
Re: Redirect Shader Idea
« Reply #11 on: November 16, 2018, 06:24:28 AM »
For anything you do in Y it's hard to see in the previews what's going on. Sometimes not even possible.

I'm with Matt and perhaps even worse, I have no idea what you are after :P

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Re: Redirect Shader Idea
« Reply #12 on: November 16, 2018, 05:24:16 PM »
Is something like this what you need?

Basically, Ulco. What I ended up doing is creating a distribution shader, and used it as the altitude limitations. Than I warped thag solid carpet of scalar which created my Y variation without warping the actual meta-layers breakup or child input.

And TU, scalar is 3d noise on X,Y,Z. So I simply want to be able to uniformly push that Y noise up and down, stretching its X and Z positions to follow Y, not warping them all based on displacement.

Think the Altitude Offset function. To be able to do this without all this nonsense would be great.

Also, the 2D Preview, because this shader warps, is an amazing way to see the tolerance of the warping.
« Last Edit: November 16, 2018, 06:13:03 PM by WASasquatch »
Art can be a window into the soul

Offline WASasquatch

  • Member
  • *
  • Posts: 3052
  • The Homeless Landscape Artist
Re: Redirect Shader Idea
« Reply #13 on: November 16, 2018, 06:30:10 PM »
This is basically what i wanted to achieve, just using a mask setup instead. Again, though, it would be nice to be able to offset XYZ by a PF colour/displacement without it creating warp effects, just redirection.

This setup allows the master Meta-Layer to use it's breakup to, well, breakup the fuzzy zone of the Meta-Layer Altitude, and fill the masked area with the density fractal, without the density or breakup being effected.
« Last Edit: November 16, 2018, 06:32:00 PM by WASasquatch »
Art can be a window into the soul