Planetside Software Forums

General => Terragen Discussion => Topic started by: PeanutMocha on September 01, 2012, 12:08:10 PM

Title: Sun showing through objects
Post by: PeanutMocha on September 01, 2012, 12:08:10 PM
I'm rendering a scene with the sun 1.5 degrees above the horizon.  However, it looks like it should have been partially obscured by trees (TGO's) on a hill.  The sun disk doesn't seem to be obscured much, if at all.  Is there anything I can change in the render settings to make the sun disk appear more realistic?

[attachimg=1]
[attachimg=2]
Title: Re: Sun showing through objects
Post by: Kadri on September 01, 2012, 01:47:16 PM

Did you look at the Atmosphere node "Receive shadows from surface" setting?
Render time will be longer. The fastest would be to make a crop render near the sun.
Title: Re: Sun showing through objects
Post by: Simius Strabus on September 01, 2012, 05:07:48 PM
I've had some poor results with cropped renders in the past. Somehow the colors are not the same. Not sure why/how that happened.
Title: Re: Sun showing through objects
Post by: Kadri on September 01, 2012, 08:18:23 PM

I think it is because of the GI calculation .
I would basically take a bigger crop and adjust it a little .

The last additions with GI caching might be a help with such problems.
If you save your GI calculation before your first render.
Although because your Sun will look different you could get still a different look not sure.

The advanced render settings might be helpful too.

I had not such a problem so just guessing  :)
Title: Re: Sun showing through objects
Post by: PeanutMocha on September 01, 2012, 09:47:41 PM
Receive Shadows from Surface was not checked.

Do I just need to check it for the atmosphere, or also for the cloud layers?
Title: Re: Sun showing through objects
Post by: Upon Infinity on September 01, 2012, 10:03:03 PM
Should just be the atmosphere.
Title: Re: Sun showing through objects
Post by: Kadri on September 01, 2012, 10:45:00 PM

Yes only atmosphere is enough.

The cloud setting is more about getting shadows from other surfaces on clouds.
As a mountain that can have his shadow on clouds below.
Title: Re: Sun showing through objects
Post by: JasonA on September 06, 2012, 08:48:22 AM
Actually Im finding that I have this issue too. 

I'm using DEM derived ter files in my scene and when I turn the camera to face the rising sun with a mountain in the way, the sun glow is in front of the mountain.   

*edit

I wondered if maybe it was non-native objects that had the problem but I tried a blank scene, created a default heightfield and pointed the camera to the sun with a really low elevation angle.  Sun glow is in front of the heightfield.

It'd be good if anyone else can confirm this.
Title: Re: Sun showing through objects
Post by: Kadri on September 06, 2012, 09:40:57 AM

Did you tried what i said in the first post in this thread , Jason ?
It is not a bug.
It is an option because (probably!) when that setting is checked render time gets longer .

If your problem is related to that setting of course .
Title: Re: Sun showing through objects
Post by: JasonA on September 06, 2012, 09:47:42 AM
ah yes Kadri, sorry I didnt try it.  I saw the comment and glossed over it because I didnt think the sun was the atmosphere.  But Youre right that fixed it.  Cheers bro
Title: Re: Sun showing through objects
Post by: Kadri on September 06, 2012, 09:53:54 AM

No problem  :)
Title: Re: Sun showing through objects
Post by: Kadri on September 06, 2012, 10:04:31 AM

Actually Jason you reminded me that i wanted to say something about this setting.
It is not a major problem but anyway...
I do not know why Matt put that setting in the atmosphere node.
Maybe because it is related to that node ,
but i always felt that the render node would be a better place to put that option.

It feels more intuitive for me to see it there.
Not sure what you guys here think about this?
Title: Re: Sun showing through objects
Post by: Tangled-Universe on September 06, 2012, 10:17:14 AM
Isn't it logical to have it either in the clouds or atmosphere?

The option says "receive shadows from surfaces" which means that *this* atmosphere element will receive shadows from surfaces.
The same goes for clouds. You can specify the need for calculating shadows from surfaces *per* cloud layer.
Clouds lower than mountain tops (for instance) would require "recieve shadows from surfaces" but the cloud layer up above in the sky wouldn't.

If you would have this setting in the rendernode then it would apply to all atmosphere or cloud elements.

Otherwise the render dialogue would need to get a dynamic update for the amount of atmosphere/cloud nodes in the network and it would also need to deal with the ones which are really active in the network node or just being passively disconnected by the user.

I can see your point, a bit, since it's related to rendering, but so are many other settings in the atmosphere or cloud node related to rendering and thus it's in the right place in my opinion.

Cheers,
Martin
Title: Re: Sun showing through objects
Post by: Kadri on September 06, 2012, 10:34:15 AM

Yes you have a point too Martin , but if you think about the sentence " receive shadow from surfaces"
it is hard to think about the Sun shining through the ground!
I would look first at the Render node or the Sun node but atmosphere wouldn't my first bet about this.

Wish there were two settings one for really only " receive shadow from surfaces" for the atmosphere
and one "Sun behind objects" kind of setting .
Of course this might have not any meaning from the render engine side, i don't know!
Title: Re: Sun showing through objects
Post by: Tangled-Universe on September 06, 2012, 01:47:36 PM
Quote from: Kadri on September 06, 2012, 10:34:15 AM

Yes you have a point too Martin , but if you think about the sentence " receive shadow from surfaces"
it is hard to think about the Sun shining through the ground!
I would look first at the Render node or the Sun node but atmosphere wouldn't my first bet about this.

Wish there were two settings one for really only " receive shadow from surfaces" for the atmosphere
and one "Sun behind objects" kind of setting .
Of course this might have not any meaning from the render engine side, i don't know!

I disagree.

The sun is a light source and the medium where the light propagates through is the atmosphere.
Shadows are cast into the atmosphere or in other words there's less light behind areas which obstruct direct light.
That's all happening in the atmosphere and the sun has nothing to do with that other than emitting light.

If I think about "receive shadow from surfaces" in the atmosphere node then I realize that it is not being calculated if it's disabled.
So what do I expect when the sun is behind terrain and the atmosphere is told to not calculate the shadows from surfaces?
I would expect that the terrain wouldn't not cast a shadow and that the light from the sun still should be visible. If it wasn't then it was casting a shadow ;)

By default the atmosphere does not receive shadows from surfaces. Why? Because in the vast majority of situations the sun is not behind/below the terrain and thus that is default.
What you describe is the symptom, not what's causing it. Therefore there shouldn't be a "Sun behind objects" option, or better said, there can't be a "Sun behind objects" option (at the moment), because the calculations required is the one provided by the "receive shadow from surfaces" option.
Title: Re: Sun showing through objects
Post by: JasonA on September 06, 2012, 08:20:54 PM
Once you know about the setting and where its at, its no big deal, but to me it was not intuitive where it was located.

Coming from Maya, I guess I think about light and shadows differently.  To me, I felt like the issue is about the light source being occluded by an object.  Which in turn makes me think about options like "cast shadows on/off" which Maya has.  when this came up I immediately went to the Sunlight node (which is the light source, and thus causes shadows), which to me seemed like the intuitive place to go.  When I didnt see anything there I immediately assumed this was some kind of bug.  It would have probably been awhille before I stumbled across it in the Atmosphere node.

Embrassingly, once going through the tabs on the node there was the little paragraph describing my exact situation so .. hehe doh on my part there.  ::)  But if i had my vote, id say the more intuitive mental paradigm would be since its a shadow casting/source occlusion issue, it should be on the light source.

*edit:  As I sit and think about this, it sort of creates the debate about what causes a shadow, the light or the object (I would consider an Atmosphere to be an object of sorts).  The light casts light and the object casts a shadow and if youre in the shadow, then the light obviously must be occluded. 

Anyways, just thinking aloud for friendly discussion :D 
Title: Re: Sun showing through objects
Post by: Kadri on September 06, 2012, 10:26:41 PM

In fact in the first place this should not happen at all.
No light should pass through objects other then transparent or clouds alike ones.

The pass through should be an option.

Martin i think you are so much in TG2 mentality (not a bad thing here)
that you sometimes forget how a beginner or other software user "feels" about these things .
This is one of the TG2 mentality things you have to know about and it is not intuitive  (as it looks to you) .
I do not remember a 3D software where a surface has a light source shine through as default .
But coding and render wise it has it place it seems in TG2 .
This is a landscape software at first and the Sun doesn't behave like this .
The artists  shouldn't hound around and make excuses because the render does this or that.
At least so much less so much better.
Does this make coding harder?
Probably! But this is not the artists problem!

Basic differences like this adds to the "TG2" is hard to use attitude unnecessarily.
As i said it is not much a problem for me too ,
this would be at the much lower part of the things to make better list.

"Please count how many digit-characters are in 6.378e+006 ? Yes 10.
Now count this 6.378.000 ? Yes more...Wait! Less... 9. Yes 9. Hmm! "


This would be a little higher on my list and only a option in the preferences Martin  :P  :)

We have still not a basic content for the beginner and-or a first time user scene .
the first default screen is an empty flat surface ...
A landscape generators first default screen should be a landscape!
I have Lightwave and it comes with its own content in a separate DVD.
A beginner can look try and learn many things just playing with those files.

This is one of the things that requires probably no coding so to speak ,
but it looks more like "this is not a problem so much" attitude on Planetside .
Because after so much years i can not think about another reason.
Title: Re: Sun showing through objects
Post by: FlynnAD on September 06, 2012, 10:33:33 PM
To add to the discussion (while simultaneously agreeing with numerous comments, both regarding Maya/Max and the beginner difficulty of TG2)...

How about this for a mental strategy:

Think about if (and it does in reality) all the sky receives "God rays". But realize that if you are completely within God rays, then you don't see them. You need an object to cast shadows, and then you see God rays.

So a mountain which is in your view blocking the sun is actually causing shadows in the atmosphere where God rays are not seen. Now you don't perceive the God rays when you look at the rest of the surrounding sky because there is only sky (and then outer space).

If there were no mountain in the way, the sky (where the sun would be) would be exceptionally bright because you're looking at a nearly infinite number of parallel God rays, except that the mountain is casting shadows on the atmosphere and blocking out those specific God rays.

So, in the end, you do want the atmosphere to have the option to "receive shadows from surfaces".

-Matt
Title: Re: Sun showing through objects
Post by: Kadri on September 06, 2012, 11:12:42 PM

Edited my above post (Yeah got in a kinda rant direction now :) )*
Title: Re: Sun showing through objects
Post by: jo on September 07, 2012, 01:16:57 AM
Hi Kadri,

You answered the reason this setting is not on by default yourself - it slows down rendering. It's not something which is always required, only when the sun is behind something. It's not a matter of coding, because obviously the renderer can handle it if you tell it to.

FWIW, I agree with you about scientific notation for numbers, I don't think it's helpful at all. We've talked about it and I hope to see it change in a future version.

We also understand the lack of sample content is a problem and will be addressing for a future version.

Regards,

Jo
Title: Re: Sun showing through objects
Post by: Kadri on September 07, 2012, 01:41:25 AM

Thanks Jo , nice to hear that you want to change that numbering .

Don't get it wrong but my first post about content was 3 years ago!

I feel better now  :D
Title: Re: Sun showing through objects
Post by: TheBadger on September 07, 2012, 09:36:42 AM
Quotemy first post about content was 3 years ago

So you have only been using TG2 a little longer than me, but you know it way better. This does not make me feel good :'( I should at least know it half as well, not .2% as well.  :'(
Title: Re: Sun showing through objects
Post by: Kadri on September 07, 2012, 12:40:59 PM

Michael  i am not sure how i should answer to your post...

I have used audio , video, 2D and 3D software since nearly 25 years as a hobby
and sometimes professionally and i used to draw in the past .
I am not quite a specialist in anything.
I am more a kind of a generalist (?) .
The software i use mostly is Lightwave actually since 17-18 years.

Here are many more TG2 users that know TG2 much deeper then i know
like Tangled-Universe and DandelO (Guys you are too many so i mentioned only 2 of you  :) ) for example.

When you begin to use the same kind of software for long years
you mostly do not begin from zero when you try another one.
I may have been using TG2 maybe only since 3-4 years but before this is at least a 15-20 year background.
So there isn't anything that you should feel bad about Michael.
You will carry all the things you learn here in TG2 , Hexagon etc. to other software
you will use in the future and the most hard part is the beginning.

You say 0.2% and that makes me think that you are very hard on yourself
because anybody who will see your models and images will certainly not look in that way.
We all see here newcomers that are here for 3-6 months
but that in so or so way give up and do not post anymore.

From your models and images that you posted i see a very bright future for you.
And i really mean it  :)
Title: Re: Sun showing through objects
Post by: TheBadger on September 07, 2012, 12:50:41 PM
 ;D

Thats probably the nicest thing I have heard in many months. Thanks kadri! I actually feel better about my perceptions of how long this is taking me.