*renamed* Lighting and shadows in games

They work, some sites were hotlinking me so I had to make a list of approved sites. Its ok now. Note: These are not lossless, I'll try to grab those soon.
 
Dot50cal, have you seen my quick Photoshop work in the upscale discussion thread?

It seems to me that using Quincunx AA (it has blur!) and upscaling from a lower resolution are just about enough to get rid of the dithering-like effect.
 
Guys, I have shots from both final retail GTA4 games now.

http://dot50cal.the-horror.com/gta4/360.jpg

http://dot50cal.the-horror.com/gta4/ps3.jpg

Same time of day on both. Looks like 360 has dithering while ps3 does not. I'd love to hear a technical explanation as to what techniques they are using, though :)

The PS3 screen shot looks like it has a blur filter applied and definitely looks to have less detail than the 360 version, esp noticeable on the bars on the windows in the background.

Would be nice to get two shots that were better aligned to make sure some of the detail differences aren't just artifacts of the slight angle difference.

Aaron Spink
speaking for myself inc.
 
R&C has "artistic" shadows instead of "correct" shadows. You don't have everything casting shadows and characters don't usually shadow themselves or each other.

Sometimes this is good, though. R&C has a cartoonish look, so realistic shadows aren't necessary. Half-life 2 shadows are quite limited in realism too, but avoid artifacts.

Good shadows are a tough problem in realtime graphics. Fortunately, there have been some great developments recently that run extremely well on current PC GPUs.

Coud you give an example, must I´ve seen look bad.

I think Drake´s Fort.. has the best light/hadow in PS3 games though, but it seems like it´s player and npc and some other thing shadoving, not evirom and so?
 
It would be nice with list of techniques and console game exemples. ould put it toghter iwith picts if some posted a list.
 
There is one thing that I have never understood to do with lighting and shadowing, if you had a good light shader wouldn't it practically do the shadowing for you? because everything that isn't lit = a shadow?. I know this doesn't work for multiple lights but it seems to me it would work for one..
 
No. Consider self shadowing, a person's arm casting a shadow across their chest. The lighting calculates light from a direction and adds it to a surface, but doesn't consider objects occluding the light source. To do that you need a ray tracing algorithm that actually scans from surface to light and sees if any ojects are in the way. That's why RT is such a nice, simple algorithm. It's just too darned slow!
 
There is one thing that I have never understood to do with lighting and shadowing, if you had a good light shader wouldn't it practically do the shadowing for you? because everything that isn't lit = a shadow?. I know this doesn't work for multiple lights but it seems to me it would work for one..

What that is that the surface normal show how perpendicular to the light it is. Smaller angle more bright, higher angle darker (Or something like that at least). So but that just works for the object. The object in it self does not cast shadow onto other objects or even on to it self. It just shows how it´s lit. This was the way ex PS2 games worked. And you can see that in the caracterfaces in many japanese games such as DM4.
 
Very good information and middleware here :

http://www.geomerics.com/


ENLIGHTEN
Enlighten sets a new standard in believability for computer games. When a game uses Enlighten, all radiosity lighting is computed dynamically in real time. When a torch moves, or a light is turned off, the scene updates instantly, with correct realistic lighting automatically computed.

Features

* Real-time radiosity
* Dynamic lighting environments
* Colour bleeding
* Soft shadows
* Character lighting
* Ambient occlusion
* Specular highlights
* Normal mapping
* HDR
* Cross-platform compatibility

How does it work?

The core radiosity runtime component of Enlighten takes the result of your direct illumination in the form of a texture, which represents something similar to a light map. It returns as output other textures representing all of the bounced light computed for that frame which can be sampled inside your shaders. Enlighten gives back sufficent information to combine the bounced lighting as you wish, and provides sample code to demonstrate potential uses of the lighting information. Through this design model Enlighten can bolt on to any existing lighting solution.

Enlighten currently requires a one-off geometry pre-compute stage, and stores the results of this for use as additional input to the runtime system. This takes of the order of 2 minutes for typical game geometry, and need only be performed once. It is also only dependent upon the geometry of the scene - not the textures, material or lights that your scene may be composed of. This allows you to re-texture and light your world in real time.
How is it used

Enlighten is delivered as an SDK containing run-time code and a series of tools and plug-ins. The runtime code in the SDK is very lightweight, and although simple to integrate, intentionally has platform specific features. This allows us to work as optimally as possible on each of our supported platforms and allows you to work closely with the core functionality

To support this SDK design, Enlighten ships with extensive sample code and utility code that can be 'peeled away' from the core components as necessary. This allows you to work with Enlighten at the level of abstraction you desire. Enabling both quick integration with the utility code, and the flexibility for you to take control.
Performance
Enlighten is available on three platforms.

Sony Playstation 3

* Enlighten is currently optimised so that the core algorithm can run sufficiently on 1 SPU, with minimal GPU usage. On a game running at 60fps, Enlighten will consume 1/3rd of the resource of 1 SPU, leaving the remaining SPU resource for the rest of the game. This may of course be increased to add detail to the radiosity solution, giving an exciting amount of scope for creativity.

Microsoft Xbox 360

* For the 360 Enlighten can be configured to balance work load across either the GPU or on one of the main threads. How you choose to distribute the work can then reflect the balance of resource demand in your system.

PC

* The PC version of Enlighten can also be configured to balance work load between the GPU and the CPU. This allows Enlighten to target the most suitable resource across a wide range PCs with graphics cards of differing capacity and those PCs with multi-core CPUs.
 
Enlighten is making some bold claims, but until we see it prove itself in game, it's hardly a reference point for other titles. If you can really get those results from the DGC vid with one third of a SPU, either there's an incredible tradeoff with RAM requirements, or all other lighting system will become redundant! Imagine if all the GPU could be turned to materials rather than lighting and shadowing?! So, nice idea, but let's see what really happens before referencing Enlighten for processing requirements of lighting and shadowing engines.
 
Enlighten is making some bold claims, but until we see it prove itself in game, it's hardly a reference point for other titles. If you can really get those results from the DGC vid with one third of a SPU, either there's an incredible tradeoff with RAM requirements, or all other lighting system will become redundant! Imagine if all the GPU could be turned to materials rather than lighting and shadowing?! So, nice idea, but let's see what really happens before referencing Enlighten for processing requirements of lighting and shadowing engines.

You are totaly right and maybe wee can see this feature,middleware whateaver soon as we espect :

March 27, 2007

Product: Geomerics Completes Enlighten For PS3

Product: Geomerics Completes Enlighten For PS3 Cambridge, UK-based Geomerics, a technology development company that targets video game developers with its dynamic lighting solutions, has announced that the company has completed work on its Enlighten software for the PlayStation 3.

According to Geomerics, Enlighten alters the way lighting is handled in games by allowing more dynamic lighting effects to be computed at run time. The news follows the recent integration of the software into Epic Games’ popular Unreal Engine 3 middleware solution.

"We are delighted to have been given the opportunity to develop on the PS3," commented Geomerics' CTO Julian Davis. "We believe that by harnessing the power of both the Cell processor and the GPU our lighting technology will help to realise the full graphics capability of Sony's console".

Geomerics CEO Gary Lewis added: "There is no doubt that the PS3 provides a massive opportunity for companies such as Geomerics. We will be creating cutting edge technologies across a range of complex and challenging areas, each optimised to take full advantage of the PS3 architecture. This will offer developers massive savings in time and cost, while simultaneously improving the quality of the games they can deliver".

http://gamedevelopment.com/php-bin/news_index.php?story=13298


March 12, 2008

Geomerics, UCL Get $1 Million Grant For Enlighten Research

Geomerics, UCL Get $1 Million Grant For Enlighten Research UK-based graphics and lighting technology company Geomerics has announced a new research collaboration with University College London, funded by an investment of £525,000 from the Technology Strategy Board's Collaborative Research and Development program.

Following the launch of its first lighting technology product, Enlighten, Geomerics and UCL will work together to further develop the technology over the three-year project. Geomerics will receive £330,000 and UCL £195,000 of the total investment.

Ultimately, the two aim to further technology that lights fully dynamic worlds in realtime. Enlighten is an SDK used to compute indirect lighting from arbitrary complex direct lighting, and can be implemented either at runtime or offline. It is modular and designed to work alongside existing lighting and shadowing schemes, and is currently available for PlayStation 3, Xbox 360 and PCs running DirectX 9 and above.

Commenting on the new partnership, UK Science and Innovation Minister Ian Pearson said: "The UK's future global competitiveness depends on innovation. The UK has world class expertise in graphics and we are a global leader across the creative industries, which now contribute over 8% of the country’s GDP."

He elaborated, "If the UK is to maintain and extend its role as the world’s creative hub, we need to continue to develop the new, exciting and innovative technologies that will underpin the creative industries in the years to come. This is why we are pleased to support this project, which will bring new and exciting technology to the games industry."
POSTED: 09.23AM PST, 03/12/08 - Leigh Alexander - LINK
divider


http://www.gamasutra.com/php-bin/news_index.php?story=17835

Here are good video and article about Enlighten:
http://www.psu.com/Geomerics-Enlighten-engine-GDC-2008-demonstration--a0002800-p0.php

(only time will tell it does work or not but im cross fingers)
 
Last edited by a moderator:
No. Consider self shadowing, a person's arm casting a shadow across their chest. The lighting calculates light from a direction and adds it to a surface, but doesn't consider objects occluding the light source. To do that you need a ray tracing algorithm that actually scans from surface to light and sees if any ojects are in the way. That's why RT is such a nice, simple algorithm. It's just too darned slow!

What that is that the surface normal show how perpendicular to the light it is. Smaller angle more bright, higher angle darker (Or something like that at least). So but that just works for the object. The object in it self does not cast shadow onto other objects or even on to it self. It just shows how it´s lit. This was the way ex PS2 games worked. And you can see that in the caracterfaces in many japanese games such as DM4.

Thanks to both of you, and it makes complete sense, so I take it the shaders are 'dumb' and as such don't know if they are being blocked by a object.
 
Thanks to both of you, and it makes complete sense, so I take it the shaders are 'dumb' and as such don't know if they are being blocked by a object.

It can get quite complicated to so self shadowing without some form of ray casting. And the problem with ray casting is that at an acceptable performance it looks pretty bad and to get it looking good requires a lot of performance.

If you really want to read up on it, Pixar has a couple good papers on what the various issues are and their solutions to them at graphics.pixar.com.

The pixar solutions tend to be fairly ideal but require lots of computation but they are somewhat interesting because the pixar rendering software, PRman, implements the REYES algorithm which is quite similar to the basic rendering algorithm used by realtime graphics.

Also its probably important to point out even pixar doesn't use all ray casting for shadows and reflections because of the massive performance costs and instead uses distance calculations to determine which pixels get ray cast and which use more simplified shadowing and reflection methods. This generally results in self reflection and shadowing using ray casting but inter object reflection and shadowing using environment bump mapping and raster based shadowing algorithms.

aaron spink
speaking for myself inc.
 
Coud you give an example, must I´ve seen look bad.

I think Drake´s Fort.. has the best light/hadow in PS3 games though, but it seems like it´s player and npc and some other thing shadoving, not evirom and so?

The majority of the environments also cast and receive shadows (except not every blade of grass casts a dynamic shadow but some do and you can see the shadow on Nathan if he's in the right place), in the indoor areas like the tunnels, when the flashlight is on, you can dynamically cast self-shadows on the environment, when both Drake and Sully have flashlights, the two light sources are able to cast shadows including self-shadows on the respective characters, there are some stages where self-shadowing is turned off for some reason and some of the light sources while able to light characters are unable to cast shadows, but there are lots of instances where even an electric spark on the wall is a light source that not only light up the surrounding environment, but can light up Drake as well as cast self-shadows on Drake. As far as PS3 games are concerned, I find Uncharted has the best lighting/shadowing.
 
The majority of the environments also cast and receive shadows (except not every blade of grass casts a dynamic shadow but some do and you can see the shadow on Nathan if he's in the right place), in the indoor areas like the tunnels, when the flashlight is on, you can dynamically cast self-shadows on the environment, when both Drake and Sully have flashlights, the two light sources are able to cast shadows including self-shadows on the respective characters, there are some stages where self-shadowing is turned off for some reason and some of the light sources while able to light characters are unable to cast shadows, but there are lots of instances where even an electric spark on the wall is a light source that not only light up the surrounding environment, but can light up Drake as well as cast self-shadows on Drake. As far as PS3 games are concerned, I find Uncharted has the best lighting/shadowing.


This...by far. So smooth and sharp - they apparently went through 10's of different techniques for their shadows. The final result is gobsmacking IMO.
 
To me shadows in saint's Row are way better than GTA4 ones, very sharp and clean, but the game is less detail et the framerate worst. I guess we can't have both this gen.
Even the cars lights cast shadow of objects they light.
 
Coud you give an example, must I´ve seen look bad.

I think Drake´s Fort.. has the best light/hadow in PS3 games though, but it seems like it´s player and npc and some other thing shadoving, not evirom and so?

Drake's Fortune is the only game I've ever seen with any kind of true shadow penumbra calculations. I was literally stunned when I saw it. Anywhere in the game where there is an indoor light shinning against a wall or when you're with Sully in one of the temples, test it out yourself, it's amazing. Outside of Drake's Fortune, I think for unified shadow systems, Crysis has easily one of the best, especially in the vain of creating realistic soft shadows. More and more games are starting to use the "noise sampling" technique to get the nice soft penumbra look.

I think the next logical step for the noise system, would be to calculate the distance of the surface the projected shadow is mapped to in relation to the distance of the object that is creating the shadow, as that relation in distance is a very important determining factor in how soft a shadow is. If you look at a pole in real life on a sunny day, you'll notice exactly what I mean. The shadow being built off the bottom has less fuzz to it, and as you go farther along the shadow, because it's farther from it's light blocking source, it gets fuzzier due to more ambient light getting in.
 
I think the next logical step for the noise system, would be to calculate the distance of the surface the projected shadow is mapped to in relation to the distance of the object that is creating the shadow, as that relation in distance is a very important determining factor in how soft a shadow is. If you look at a pole in real life on a sunny day, you'll notice exactly what I mean. The shadow being built off the bottom has less fuzz to it, and as you go farther along the shadow, because it's farther from it's light blocking source, it gets fuzzier due to more ambient light getting in.
Percentage closer shadows do this. PDF about it and video of it here:
http://developer.download.nvidia.com/SDK/9.5/Samples/featured_effects.html
 
Back
Top