Planetside Software Forums

General => Terragen Discussion => Topic started by: cyphyr on April 19, 2009, 05:50:27 PM

Title: Translucancy and Brightness
Post by: cyphyr on April 19, 2009, 05:50:27 PM
Hi guys
This is a problem I've been comming across for a time. Every time I increace the translucancy of an object it also gets brighter, this kinda works if the object is against a bright or luminous object, like the sky for example, but is not so good if the object is against a darker background such as the earth or ground. I can get arround this by making the objects colour darker but this wont work on populations where they are set against both bright (sky) and dark (ground) backgrounds.
Any suggestions?
:)
richard
Title: Re: Translucancy and Brightness
Post by: Mohawk20 on April 19, 2009, 07:07:18 PM
How high are your translucency values? Did you try the Lambert shader in stead of normal default shader translucency (just apply the same settings and plug it in as translucency function)?
Title: Re: Translucancy and Brightness
Post by: cyphyr on April 19, 2009, 07:21:21 PM
Translucency values are high, over 1 and up to 8 sometimes. I have not tried the Lambert shader but I did wonder if that was the right direction to go, never understood its function properly, I'll give it a go, ta :)
richard
Title: Re: Translucancy and Brightness
Post by: Mohawk20 on April 20, 2009, 03:06:07 AM
Well, It could be that the results are the same, I don't know. But it's normal that high values would give light results...
Title: Re: Translucancy and Brightness
Post by: moodflow on April 20, 2009, 03:38:22 PM
I've also found that values above 1 tend to have this issue.   Occasionally, you can get by with higher settings... it just depends on the scene.

I think I remember Matt (or Oshyan) saying something about how the translucency function wasn't fully developed yet and is still in its primitive stages.
Title: Re: Translucancy and Brightness
Post by: Matt on April 26, 2009, 10:32:54 PM
A translucency value of 1 means that a surface facing fully away from the light source will have the same brightness as if it were facing fully towards the light source. In some materials it may be realistic to go above 1, but I think they would be very rare materials on microscopically thin surfaces (i.e. so thin that they don't reflect much light, they just scatter it). Leaves should never go above 1 if you want it to be 'correct', because leaves always reflect more light back towards the light source than they let through to the dark side.

(Setting translucency to 8 means that the "dark" side of your object is 8 times as bright as the side which is facing the lightsource!)

Remember, this is only for one surface. If you have a tree full of leaves, they all cast shadows. It doesn't take many leaves to put everything into shadow. Global Illumination tries to account for any light which might get scattered between the leaves. I don't know if that's the kind of situation you're talking about though.

Matt
Title: Re: Translucancy and Brightness
Post by: Matt on April 26, 2009, 10:38:06 PM
There seems to be some myth surrounding the Lamber Shader. The Lambert Shader is just a diffuse surface (i.e. it has less capabilities than a Default Shader). It has translucency controls, but so does the Default Shader.

Using the Lambert Shader as an input to some function or colour shader connection doesn't give you any benefits - it just returns the colour, and you would get the same results by plugging in a Constant Shader or simply specifying the colour you want in the shader if that possibility exists.

Matt
Title: Re: Translucancy and Brightness
Post by: rcallicotte on April 27, 2009, 07:58:46 AM
Hey, this is all good to know.  Thank you for explaining, Matt.  Sounds like we could actually have some fun playing with translucency for some odd effects, if we wanted to goof around.
Title: Re: Translucancy and Brightness
Post by: Mohawk20 on April 27, 2009, 11:12:08 AM
Quote from: Matt on April 26, 2009, 10:38:06 PM
There seems to be some myth surrounding the Lamber Shader. The Lambert Shader is just a diffuse surface (i.e. it has less capabilities than a Default Shader). It has translucency controls, but so does the Default Shader.

Using the Lambert Shader as an input to some function or colour shader connection doesn't give you any benefits - it just returns the colour, and you would get the same results by plugging in a Constant Shader or simply specifying the colour you want in the shader if that possibility exists.

Matt


So what is the benefit of using the Lambert shader anyways? What I mean is, why did you create it in the first place?
Title: Re: Translucancy and Brightness
Post by: Cyber-Angel on April 27, 2009, 01:06:34 PM
Mohawk I think the Lambert Shader was created to help with situations as described here http://www.tonmeister.ca/main/textbook/node224.html though weather the Lambert Shader conforms to Lambert's Law I don't know, hope that like is helpful.

Regards to you.

Cyber-Angel ;D   
Title: Re: Translucancy and Brightness
Post by: cyphyr on April 27, 2009, 01:36:38 PM
Ok I get how this works but in that case how would you advise I make an image like this?
I can only get similar results by ramping the translucancy up higher than 1
thanks
Richard
Title: Re: Translucancy and Brightness
Post by: PorcupineFloyd on April 27, 2009, 01:41:08 PM
Have you tried pumping up GI strength and reducing the exposure while maintaining high translucency parameters?
Title: Re: Translucancy and Brightness
Post by: arisdemos on April 27, 2009, 03:39:43 PM
@ Matt, does the setting information you provided on translucency apply to say a plant which will need to show an even greater amount (than, say leaves) of backlighting or glow quality like the Xfrog "Cholla" that has/needs a very pronounced lighting presence against an over all darker background?
Title: Re: Translucancy and Brightness
Post by: Matt on April 27, 2009, 07:43:18 PM
Quote from: Mohawk20 on April 27, 2009, 11:12:08 AM
So what is the benefit of using the Lambert shader anyways? What I mean is, why did you create it in the first place?

It was one of the very first shaders I wrote because it is one of the most simple shaders. Because it only does diffuse illumination, it is faster than the more complex shaders such as Default, Surface Layer etc., so it might be useful if all you need is a very basic surface. But it does not do anything special that the other shaders don't.

Matt
Title: Re: Translucancy and Brightness
Post by: Matt on April 27, 2009, 07:45:13 PM
Quote from: Cyber-Angel on April 27, 2009, 01:06:34 PM
Mohawk I think the Lambert Shader was created to help with situations as described here http://www.tonmeister.ca/main/textbook/node224.html though weather the Lambert Shader conforms to Lambert's Law I don't know, hope that like is helpful.

Yes, it implements diffuse illumination according to Lambert's law. All of the other shaders in Terragen that have diffuse colour do the same, so the Lambert Shader is nothing unusual.

Matt
Title: Re: Translucancy and Brightness
Post by: Matt on April 27, 2009, 07:48:18 PM
Quote from: arisdemos on April 27, 2009, 03:39:43 PM
@ Matt, does the setting information you provided on translucency apply to say a plant which will need to show an even greater amount (than, say leaves) of backlighting or glow quality like the Xfrog "Cholla" that has/needs a very pronounced lighting presence against an over all darker background?

Yeah, it might be useful to give the impression of scattered light from fine hairs. But it's not really an ideal solution because really you'd want that effect to happen only when looking close to the direction of the sun. But if it works for a particular image, then yes you could use that.

Matt
Title: Re: Translucancy and Brightness
Post by: Oshyan on April 27, 2009, 11:58:48 PM
Replicating that leaf image closely might be possible through either an increase in Exposure, or adjustments to GI Strength on Surfaces. I grant that the "easiest" way to do it is through translucency above 1 though. I'm not sure whether this is just realism clashing with our idea of what it "should" look like, or simply due to lack of simulation of some important additional parameter.

- Oshyan