Raising a simple shape shader

Started by Erwin0265, October 10, 2014, 07:19:00 am

Previous topic - Next topic

Erwin0265

Hi all,
It's been a while since I've browsed the forums; basically, I felt I was getting nowhere (learning Terragen) and went back to Vue.........
Anyway, finally someone has created a series of tutorials that I can follow and perhaps learn something (fingers crossed).
So, I have been following the Geekatplay Terragen 3 tutorials and am currently trying to follow along to the "Lake View" tutorials (they're part of the "Exploring Terragen 3" tutorial set).
Near the beginning of the tutorial, Vlad uses a Simple shape shader to create a nice, flat area.
This is fine; no problem; I have a nice, circular flat area.....
But silly me wants to raise it a bit.....
There is a position setting in the shader preview window (x,y,z); so I increase the Y value from 0 to 100; nothing; to 1000; nothing; to 10000; nothing............
I can select the shader in the 3D preview window and bring up the gizmo (or whatever it's called in T3) and I can drag on the green arrow to my heart's content; but it doesn't do anything other than raise the upper "ring of dashes", but this has no effect (so why have it at all....?)....
There has to be a simple way to raise the leveling effect of this shader...................
But how do I do this?
Please remember, I'm an absolute noob at Terragen and although I did find a solution to this (http://www.planetside.co.uk/forums/index.php/topic,12659.msg126050.html#msg126050); it was so complex that I have to ask; surely there is a simpler way?
Why would we not be able to raise or lower a shader that levels an area of terrain (especially when there is a Position setting for it)?
OK, who farted?

Oshyan

Go to the Displacement tab of the Simple Shape Shader and switch from "Displace relative to surface" (the default) to "Displace relative to shader position". That will allow the displacement "height" to be controlled by shader position. However it may not produce the results you want, depending on what you're actually aiming for. Alternatively you could try leaving it at Displace relative to surface (which will give a smoother, more contiguous result) and increase Displacement Amplitude. It is measured in Meters.

- Oshyan

Erwin0265

Hey Oshyan, thanks for the speedy response.
I tried all of your suggestions with zero effect; nothing I do moves that damn shader...............
I've attached a few screencaps, so you can see the settings (in case I misunderstood)............
Am I doing anything wrong?
OK, who farted?

yossam

You need to check the box that says apply displacement.  ;D

Oshyan

Indeed, as Yossam says. Also if this is derived from the Default scene, the Simple Shape Shader in that case is being used as a mask, so Displacement won't have an effect anyway. If you do have the Simple Shape Shader as part of the main Terrain shader chain, then it will work with the Displacement checkbox enabled.

- Oshyan

Erwin0265

QuoteYou need to check the box that says apply displacement.  ;D
:-[ Oops.............

QuoteAlso if this is derived from the Default scene, the Simple Shape Shader in that case is being used as a mask, so Displacement won't have an effect anyway.
???
Remember - noob; I have no idea as to what you mean..
FYI; I created the terrain by first deleting the original terrain, leaving only the Fractal warp shader. Then I added a Power fractal/Fractal terrain.
The order of the terrain layers was changed to have the Fractal terrain first (along with it's accompanying Simple shape shader) and then the Fractal warp shader.
To be honest, I have no idea as to why the order needed to be changed (it was done that way in the tutorial but the explanation as to why was unclear  {Vlad is great in that he creates all of these tutorials for numerous apps, but he can, at times, be hard to understand; given the Russian accent and his tendency to mumble..}................

Anyway, after all is said and done; checking the displacement box had no effect either............
Vlad didn't address this issue at all as his Simple shape shader magically appeared at just the right height............
Any other suggestions regarding the Simple shape shader?
OK, who farted?

Oshyan

October 11, 2014, 11:21:04 pm #6 Last Edit: October 11, 2014, 11:22:53 pm by Oshyan
Your Simple Shape Shader is appearing as a child of the Fractal Terrain 01, so it's most likely being used as a Mask. This just means that the Simple Shape is being used to control the area of effect of the Fractal Terrain; it is masking the effect of the Fractal Terrain's displacement. Masks are interpreted as black and white, where white is "full effect" and black is "no effect" for the shader being masked. In this case the Fractal Terrain shader's effect is to create displacement (mountains), so with a Mask, where the shader that is going into the Mask input is White you will have mountains and where it is Black you will have no mountains (flat, back to the default, undisplaced planet sphere). In the default scene however it's actually setup with the mask *inverted* (this is a checkbox in the Fractal Terrain's Mask settings at the bottom of its properties), and as a result where the Simple Shape is white (within the 5-sided, 10,000 meters-per-side area) will be *no* displacement (no mountains) from the Fractal Terrain shader, and where there is black from the Simple Shape shader (outside of the shape it defined) will be mountains.

Thus this is the long way around of describing that the flat area you're seeing is not the Simple Shape Shader *making* flat, rather it is the Simple Shape Shader *preventing* the Fractal Terrain shader from making mountains in that area, and thus you are seeing the flat surface of the default planet. *That* is why it is not being raised intuitively, because that flat surface is not being directly caused by the Simple Shape Shader's displacement, but rather because of its use as a mask. It is the *absence* of displacement rather than a subsequent *flattening* of a previously displaced area.

Also to be clear, the height and displacement amplitude of *any* shader have no effect when it is used as a mask because masks only interpret color, the Mask input ignores displacement.

So, long story short, if you want to displace an area controlled by a Simple Shape Shader and use its height or displacement amplitude to control terrain height, don't use it as a Mask for another shader. If you use the Add Terrain button and add another Simple Shape Shader and enable displacement, you should be able to get the effect you want, more or less. However be aware that it will not be inherently flat or smooth! It is applying displacement *on top of* the existing terrain shape created by the shaders above it. Displacement, from any shader, does not inherently create flattening.

To really get the effect of a flat area *within mountains* that you can control with the height of the Simple Shape Shader, I think you'd want to *copy* the Simple Shape Shader you already have, and add it to the node network in-between the Fractal Terrain and Fractal Warp Shader, then enable Displacement. The reason I say copy is so that both Simple Shape Shaders will have the same size and edge settings. The end result should be that you displace (raise or lower) the flat area that has been previously created by the other Simple Shape Shader that is being used as a mask.

OK, I hope that's helpful. :)

- Oshyan

Erwin0265

October 12, 2014, 07:01:00 am #7 Last Edit: October 12, 2014, 07:09:01 am by Erwin0265
Yes!
We have progress!
Putting the Simple shape shader in between Fractal terrain 01 and the Fractal warp shader appears to be having some effect.
However, I disconnected the original SSS as it appears to be having no effect (?)............
Now, I can control the height of the displacement (and the top is dead flat when using the "Displace relative to shader position" option) but can't get the edge to respond to any of the controlling parameters (Edge profile/width/units).

Separate question: what is "Position key"? I checked the Wiki but there's no explanation for that parameter..........
Another separate question: The preview window doesn't automatically render when a change has been made (it does sometimes, but less than 25% of the time); is there a quick/easy way to trigger a preview render? I've been clicking in the preview window (a habit from using Vue) and scrolling back and forth slightly (hoping not to change the camera location), but this is not really desirable due to possibly changing my camera location................

I again watched the Geekatplay tutorial showing this part of the process (ie. Creating a flat area for a lake) and he does actually talk about using the SSS as a mask; in fact, he uses the "Mask by shader" parameter in the Fractal terrain 01.......
And Terragen just crashed!
Guess who forgot to save at any stage of this project..............
Ahhhh crap!
Oh well; serves me right; BUT I must say; T3 has crashed on me 3 times in as many days (so you'd reckon I'd remember to save, wouldn't you?); I can't recall T2 ever crashing on me............... [v3.1 (build 3.1.02.0)]

Oshyan, I have to thank you for your persistence and willingness to help me (as well as many others); it may be part of your job, but you do it better than anyone in any of the various app forums that I have used/browsed over the past 5 or so years during my quest to learn 2D/3D digital art practices...........
Perhaps it isn't said enough, but I truly appreciate your genuine efforts to help me learn Terragen. Never lose that dedication; Planetside would be lost without you...........................
OK, enough with the mushy stuff; there's more learning to be done.
Again, I have attached a screencap to hopefully shed some light on what I am doing wrong....................
Whilst I wait for help, I will recreate the scene (if you can call it that; I've barely started and gotten stuck here) as best I can.
Thanks again.
OK, who farted?

Erwin0265

I really don't want to give the impression that I am being impatient for help; I am quite content to wait for when someone has the time and knowledge to help; but I also wanted to be sure that it was clear that although there is progress, I still have a few issues to resolve before being able to go on with this project/tutorial.
I can't get the edge to respond to any of the controlling parameters (Edge profile/width/units).

I also had a few separate questions (if anyone has the time):
What is "Position key"?
The preview window appears to not automatically render when a change has been made (it does sometimes, but less than 25% of the time); is there a quick/easy way to trigger a preview render?

OK, that's it.
Hopefully, someone has the time to help me just that little bit further and then I can get back to it...............
Thanks.
OK, who farted?

jaf

You could click one of the icons in the preview window, like clouds on/off.  Click it to reverse it's state and a preview render should start.  Click it again and it will restart in the original state.
(19oct19) Ryzen 1800x, 970 EVO 1TB NVME-M.2 SSD, Corsair Vengeance 64GB DDR4 3200 Mem,  EVGA GeForce GTX 1080 Ti FTW3 Graphics 436.48 (02oct19), Win 10 Pro x64, Terragen Frontier 4.4.39 BMark 0:10:18

Erwin0265

Good idea, Jaf; thanks..........
Any ideas regarding getting the SSS edge to respond to any of the controlling parameters (Edge profile/width/units)?
That's still my main problem stopping me continuing with the tutorial/project...........
OK, who farted?

Dune


Erwin0265

Hey Dune, thanks for your input.
I had a look at your tgd but it goes back to using the SSS as a mask (which is pretty much what Vlad does in the tutorial but with his example the height works fine [ie. he didn't need to adjust the height]; on mine it does not) which Oshyan told me I shouldn't do as I will have no control over the height of the flat area; which is what I am after.
From Oshyan's advice, I created another SSS [an exact copy of the one being used as a mask] and placed it in between the Fractal terrain and the Fractal warp shader.
This gave me control over the height of the flat area but I lost control over the edge profile/width/units.
I must also include the fact that I deleted the original SSS that was being used as a mask [so it was a child of the Fractal terrain; as in your tgd] as it appeared to be having no effect on anything; perhaps I was wrong..........
Anyway, I have attached my tgd for your perusal [not that there's much to it - I barely got started before I got stuck]...

To summarise; what I am basically after is both the ability to control the height of the flattened area as well as the edge profile so as to allow me to blend it into the existing Fractal terrain.
I also want to be able to control the size, of course, but that doesn't appear to have been an issue [ie. at least that works... lol].

An additional question (especially as you appear to have changed the default setting; what does the "Position key" parameter do?
I have also attached the warnings dialogue that popped up when I opened you tgd; it's probably just because our content is located in different places but I didn't understand most of it so thought I'd include it for a translation....
Thanks to all who have so far helped me; and will hopefully continue to do so
OK, who farted?

Dune

Something like this perhaps? No worries about the warnings, I work in another version.

Erwin0265

OK, this is going to make you see just how much of a noob I am:
Your tgd opened fine but the preview is just plain bizarre!
This may be the result of T3 to T2 or vice-versa; I have no idea - but the camera focal length was 2mm.
I changed it to 35mm but the preview was still very stretched.
I created another camera and linked that to the renderer but it was still distorted.
So, I have yet to see what you have done; other than in the (sorry, no idea what it's called) top left hand window where I can see you've added a Surface layer node (I have yet to read the description of the node  as I have not come across it before)....
I have attached a screencap of the strange preview as well as a render of same (for what it's worth); this is exactly how the file opened - I can't imagine you would have saved it this way.........
Although it's probably an easy fix for anyone who has a clue; unfortunately, I'm not one of them............
OK, who farted?