This topic is now archived and is closed to further replies.


How'd they do that??!

Recommended Posts

Here''s a screenshot from Need for Speed 5 (Porsche Unleashed): Please tell me: 1. How did they get the lights (and shadows) to light up / darken the ground? 2. How did they get the lights and shadows to reflect on the car, dynamically? 3. How did they make the actual lights? In the game, the light rays change as you change camera angles, making the lights seem VERY real. The lights also change in intensity, so if you look from the side they''re really dim, if you look right into a light it''s really bright. 4. The car lights up a surrounding area of about 10 m, if the headlights are on. Did they use conventional spotlights for this, or did they have some advanced light-mapping techniques? Thanks in advance for your replies.

Share this post

Link to post
Share on other sites

probably because they have been doing it for many years

Most likely the lighting is done entirely via custom rendering code (D3D lights are ok for some applications, but for truly realistic lights (like those found in a commercial game)they just aren''t adequate).


Sometimes I think I know what I really don''t, but then again usually I do know what I don''t, but just don''t realize it, maybe its because I am so young, but then again it could be because I am insane.

Share this post

Link to post
Share on other sites
1. Either static light maps (the lighting can be calculated offline with a program like LightScape and stored into lightmaps when the levels are being built). OR pre-computed vertex colours (vertex paint in the art tools).
Looking at the shot it''s difficult to tell - there are some tell tale vertex colouring (vertex paint) things. (The way the yellow colour cuts off at the end of the block to the right of your text). But at the same time the lighting is too smooth for the low polygon geometry typically used in a game.

2. If they were static lightmaps, those maps could also be projected onto the cars as an environment map.

3. Again, pre-computed lightmaps. Programs like LightScape use radiosity to model how radiation bounces around the scene. This isn''t currently a realtime technique, but very well suited to computing light maps. Traditional vertex lighting in D3D and OpenGL is only a first order reflection model. i.e. it only models the angle at which the light directly hits a polygon.

4. Either conventional lighting or another set of projected lightmaps (if they cast in a very rounded way, then they''ll be lightmaps.)

Lightmaps and projected light maps really are VERY cheap if the textures are in video memory and you have fill rate to spare.

Simon O''''Connor
Creative Asylum Ltd

Share this post

Link to post
Share on other sites