Product Chat / dynamic VS static lights What is the difference???

Author
Message
stor
9
Years of Service
User Offline
Joined: 27th Feb 2015
Location:
Posted: 25th Jan 2017 09:58
and what is the difference in performance and display quality?
PM
Kalle801
10
Years of Service
User Offline
Joined: 8th Jan 2014
Location: Germany
Posted: 25th Jan 2017 11:12 Edited at: 25th Jan 2017 11:13
dynamic can be taken "on/off" etc. Static light is baked in to the textures.

Example: Making Shadows static (Baked into textures) will increase your performance.
Wolf
Forum Support
17
Years of Service
User Offline
Joined: 8th Nov 2007
Location: Luxemburg
Posted: 25th Jan 2017 11:37 Edited at: 25th Jan 2017 15:20
Kalle has pretty much explained it in a nutshell.

Static lights are directly "baked" on to the textures of your (static) environment. A good way to put it would be to say that static lights are prerendered.
In theory, these should make you gain a lot of performance as way less calculations have to be done than when you use dynamic lighting. However, in GG, this is not necessarily the case. Static lights do not interact with dynamic objects or characters.

Dynamic lighting is real time. The source of the lights are calculated constantly and so are the shadows that dynamic objects cast. Static lights ignore dynamic objects entirely. With our current renderer, dynamic lights don't cast proper shadows, these are all derived from the sunlight as of now.
You'll also find out that the engine only renders a small amount of dynamic lights on your map (I think the correct number is 5 ? EDIT: Correction! Its 3 ) So you have to use them sparingly. However, it will always load the lights closes to the camera and deactivate those farthest away. This means that you can have several dynamic light sources in your map.

Lighting has been a large discussion during the years of GG's development. You can read some in this thread here. Baking has been an oddity with this engine and in that thread you can read how I pioneered actually using it to some effect with plenty of necessary workarounds.

My GG rule of thump is that outdoor levels should be lit in realtime because the shaders look way better that way and so do the shadows of foliage etc. while indoor levels (or levels that have a lot of light sources that need to be displayed permanently) should be baked.

Note that real time currently looks rather unfortunate in most indoor-levels.

Samples:

Realtime






***


Pre-Baked


***








Generally speaking: Realtime lighting allows for the superior shading of moving objects and characters. It gives us the abilites of having physically correct shadows in motion as well as moving lights (such as a flashlight attached to a character). However, in GG, things are different than in many contemporary engines and you have to carefully choose what is better for your current scene.

The majority of games released in the last decade use baked lights with a few dynamic lights sprinkled in. Dynamic lights are way more hardware demanding. Making games that are entirely lit realtime (dynamically) are few as this is a relatively recent venture.



-Wolf
Belidos
3D Media Maker
9
Years of Service
User Offline
Joined: 23rd Nov 2015
Playing: The Game
Posted: 25th Jan 2017 12:04
Quote: "You'll also find out that the engine only renders a small amount of dynamic lights on your map (I think the correct number is 5 ? ) "


I'm pretty sure it's only 3, i have 4 dynamic lights in my little apartment scene and as you walk around you can clearly see the furthest lights turn off.

i5, NV960 2GB, 16GB memory, 2x 2TB Hybrid, Win10.
Pirate Myke
Forum Support
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 25th Jan 2017 14:01
Yes only 3 dynamic lights can be on at the same time right now.
Intel(R) Core(TM)2 Quad CPU Q6600 @ 2.40GHz, 2400 Mhz, 4 Core(s), 4 Logical Processor(s), 8gb RAM, Nvidia gtx660, Windows 7 Pro 64bit, Screen resolution 1680 x 1050.

Ertlov
GameGuru BOTB Developer
17
Years of Service
User Offline
Joined: 18th Jan 2007
Location: Australia
Posted: 25th Jan 2017 14:30
Quote: "My GG rule of thump is that outdoor levels should be lit in realtime because the shaders look way better that way and so do the shadows of foliage etc. while indoor levels (or levels that have a lot of light sources that need to be displayed permanently) should be baked."


I fully agree with wolf here, however, I have to add some notes here:

1. For outdoor levels, realtime is the way to go, and you should avoid placed light sources as far as possible. If you have some buildings where you absolutely need a light source inside, make this as small as possible and certainly so that there are no objects that swould cast shadows from this light source. A missing shadow is an extreme immersion-braker on the subliminal level.

2. Indoor levels should be baked, as Wolf sayed, but the current lightmapper settings are by default not sufficient to allow a detailed light / shadow painting. Open the setup.ini and look for those values:



Play around with the settings. I personally use 900 - 1200 for Quality, and 2048 in the sizeentity line.
AMD FX 8Core @ 4GHZ - 16 GB DDR4 - 2xRadeon7950 - Windows 7 Ultimate
Mouaa
User Banned
Posted: 25th Jan 2017 15:41
I prefer to see games with uniform ligthing and great shadowing and some subtle lights coloring or some emissive models instead of lightmaps with strong lights colors , and too many colors , many GG games looks like rainbow games.
Ertlov
GameGuru BOTB Developer
17
Years of Service
User Offline
Joined: 18th Jan 2007
Location: Australia
Posted: 25th Jan 2017 16:03
Strong (in the sense of highly-saturated) light colors are an often-made mistake by beginners, no matter which engine.

But good shadowpainting currently needs pre-baked shadows, unless you are 100% outdoor.
AMD FX 8Core @ 4GHZ - 16 GB DDR4 - 2xRadeon7950 - Windows 7 Ultimate
Wolf
Forum Support
17
Years of Service
User Offline
Joined: 8th Nov 2007
Location: Luxemburg
Posted: 26th Jan 2017 04:08
Unless its the style of the game as in something like "Far Cry Blood Dragon" I do agree.
I like developers taking risks with style and colours but it has to work. Too many developers rely on the same contemplary contrast throughout all levels which can get dull.



-Wolf

Login to post a reply

Server time is: 2024-11-24 19:07:40
Your offset time is: 2024-11-24 19:07:40