Spot on! Light objects - my go at visible lights

Started by KlausK, December 08, 2017, 06:39:18 PM

Previous topic - Next topic

N-drju

Well, I'm not entirely proud of it, because, as I said, the render time increased considerably with quadrupled sun. :-\ Completely different behavior from what Klaus achieved.

I think there is no significant change in the bluesky, because the light is simply equally shared between all light sources. :)

For example, if your planned light strength is 4.5 and you want to get smoother god rays, all you need to do is to create, say, five suns with light strength 0.9 each. The overall brightness effect will equal your planned 4.5, but the shadow / light ray sharpness will gain. :)

Hm, for now however, I can't seem to reproduce Klaus' achievement of having same render time for increasing number of light sources.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

Oshyan

The light beam rendering quality issue is pretty specific to localized light sources, particularly the spotlight. While you can get noise in "godrays", it is almost always easily solved by increasing atmosphere samples a bit, especially when Defer Atmo is enabled. So I don't think it's really useful to use the multi-light workaround for that situation.

- Oshyan

N-drju

Hmmm, sorry Oshyan but I'm not really sure if it works. Just this weekend I finished rendering a scene with a sun peaking over the mountain, casting a simple shadow down the valley. Atmosphere samples were set at 62 with haze at 0.82 and the edge of the shadow was grainy nonetheless. ::) Sure, it was better than the test value of 14 but still not quite there...

Maybe combining samples, deferred atmosphere and duplicated sunlight can yield better result.

I am still waiting on Klaus' comment though. The idea with spotlights seems like something one would invent early on in TG. But most of us don't really have time to just experiment. So we create things and only then try to solve problems on the go. I'm glad he discovered it!
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

N-drju

Oh, I should probably also mention that turning off the soft shadows in the duplicated sunlights reduced render time by about 28% but also slightly increased graininess. I have yet to see how it affects object shadows...
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

KlausK

Hi N-drju
"... the render time increased considerably with quadrupled sun. :-\ Completely different behavior from what Klaus achieved."
"But maybe what works for the spotlights, does not necessarily have to work for the sunlight(s)?"

I think that might be the case.
I do not know how TG calculates the Lightsource objects compared to the Sun Light Object but I can imagine that it is because
of the vastly different dimension in terms of which factors (other scene relevant calculations) are influenced by the light
makes a significant difference in render time. The spotlights on the other hand cover only such a small percentage of scene overall
- perhaps to small to add to rendertime even with multiple sources. Perhaps a programmers insight could shed some light on this?

And remember that the non-increasing render time thing was only true as long as the spotlights only lit "Atmosphere and Clouds",
had "Glow in Atmosphere" turned on and "Cast shadows" turned off. As soon as I introduced the Cloud Layer render time went up.

Your example looks really good from top to bottom.
Even if render time adds up with each added sun light the question would be how these render times compare to the common 1 sun approach.
I doubt you would achieve such a good result just by increasing samples or Quality settings alone. Btw. even carefully placed spotlights in the sky
can help to produce sharper god rays.
Cheers, Klaus

ps: the technique of stacking spotlights is something that stems from the days when Global Illumination was not part of a 3D program.
So, I merely adapted the idea to my TG workflow. It is nice that it worked out so well in this case.


/ ASUS WS Mainboard / Dual XEON E5-2640v3 / 64GB RAM / NVIDIA GeForce GTX 1070 TI / Win7 Ultimate . . . still (||-:-||)

N-drju

If you like the previous set Klaus, I guess you should see this. The third image that combines all quality augmenters and tweaks speaks VOLUMES. A great, great set of variables for final renders (obviously too heavy for testing).

[attach=1]

The third image is incomplete, because I did it at my sister's and had limited time window. ;)

So let's break it down a bit... I believe that, in case of sunlight, if you want very detailed and impressive results a combination of factors will do wonders. However, be ready for a quite heavy render time. The third image took more than two hours to complete... But the result... wow. Note that the number of atmo samples is also much lower than in an image using only single sun!

I also admit that Oshyan was right that increasing number of atmo samples and deferring atmosphere may improve the quality of god rays, as the second image shows. This method is a tad less effective than sun duplication but the difference is not that great. Hence, increasing samples plus checking the deffer atmo parameter should be good for most uses. While experimenting, I also found out that increased number of atmosphere samples does not influence the render time as much as I feared it does. I rendered several tests ranging from 32 samples to even 112 and the time difference was quite acceptable in fact. :)

To summarize - just as with your spotlights Klaus, god ray shadows will also gain if cast by multiple suns. The combination of factors in the third image will yield FANTASTIC sharpness and final result but should perhaps be used as a very final render. I.e. after you are happy with the placement and direction of light, clouds and whatnot.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

bobbystahr

#21
I have a file I use often from chornor, RIP, that uses 128 atmo samples and the scene renders as swiftly as most of mine do(well as fast as my computer will do), that's often a consideration as well.

and looking at your images I notice AA3...well for finals I often use 6 and sometimes 8 when there's detailed atmo involved.
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

N-drju

Quote from: bobbystahr on December 13, 2017, 06:37:56 PM
and looking at your images I notice AA3...well for finals I often use 6 and sometimes 8 when there's detailed atmo involved.

Yes, that's the point - if it looks THAT good with this AA value and with this small resolution, imagine how these options would play out with "final" values!

I guess the lightsource object is what remains to be explored now, once spotlight and sun are covered. :)
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

Dune

Interesting. It would be easiest if TG could mix/jitter the sample jitter of one sun in maybe a few slightly different computations of the light, but I guess that would increase render time the same way.
So, how much does in influence render time, is that a few percents (I guess so)?

N-drju

Which feature do you mean Ulco?

More atmo samples renders faster than duplicated sun influence if that's what you ask. With the latter solution being slightly better in quality terms though.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

Dune

It's not a feature, just a wish, an idea that came up. May not be feasible or practic at all.

Thanks, yes, slower is usually better quality. Lets invert that!  :P

Oshyan

The increase of atmo samples probably has such little effect because the max samples per pixel is *limited* by your AA (with Defer Atmo enabled). So with AA at only 3, you are basically just making everything take max samples *for the chosen AA level* by increasing atmo samples so high. It does not mean 128 actual samples will be taken. The same is not true when Defer Atmo is of - in that case you are directly influencing number of atmo samples with that setting.

So I would suggest, rather than increase atmo samples beyond, say, 16 or 24, instead increase AA to just 4 and see what happens. In theory your multiple suns solution should not (I think) ever be more effective than just using "ideal"/best sampling settings with a single sun. I think you just are not using optimal settings. If you send me scene files to test I can probably suggest something better... Ultimately our goal is to never have to use such "hacks" just to get good quality, and as far as I know we already do not have to (although there are always difficult cases that take longer to render).

- Oshyan

N-drju

Quote from: Dune on December 14, 2017, 02:35:10 AM
So, how much does in influence render time, is that a few percents (I guess so)?

@ Dune - I meant this question.

@ Oshyan - I'm sorry but I'm just not buying it... Whenever I increase the atmosphere sampling the result is better even at the same AA level... A fact. :-\

I consider Klaus' idea with spotlights and this analogical one with sunlight to be more effective than the "standard" solution. Actually I also like some workarounds much better than standard ideas. I consider them to be "that extra effort", finishing touch if you will, that makes render perfect.

For example, I still prefer to use ancient dandelO's solution for creating cloud masses, because localized cloud shading and lighting is complete nonsense to me. I don't get quite as much problems using this solution compared to the "standard" way...

Also, I have no need to send any files because I do not have a problem with that. ??? And I guess I'm ready to wait one hour longer for the final. No biggie.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

Dune

Ah; I meant having 2 or 4 suns instead of one. But it's not important, so never mind.

N-drju

#29
I don't remember the numbers actually, but each sun adds about 50% to the render time unfortunately. :-\ This sucks, I know. But I still think I will use it for finals. As a point in case, consult the image below. My last one (for now) as far as this discussion is concerned and not half bad if I may say so myself:

[attach=1]

Atmo samples = 256 (!)
Sunlights = 2 (1.8 each)

Detail = 0.55
AA = 3
Defer atmo = on

GI cache det. = 2.75
GI sample q. = 2.75
+ supersample prepass

_______________________________________________________

@ KlausK - Klaus, sorry for hijacking your thread like this, but I find your solution very insightful (as you can obviously see.) The look of your light beams is really nice to look at, so it just gives a nice, good kick to pursue for the same in sunlight objects.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"