# Lightmap previewer (i.e. real-time lightmaps)?

This topic is 4648 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

I'm wondering if anyone can recommend any good real-time lightmapping techniques. I've already found an implementation with some interesting insights at section5 (so don't waste your/my time and tell me to google it) but am looking for more options. I don't need anything full quality, but at least of decent quality and as quick as possible (preferably hardware accelerated, like the ambient occlusion stuff from nvidia or even ambient occlusion fields). The point is not to generate production quality lightmaps but to offer the artist a quick path to see how a level will look when moving any static lights around. I'm also curious what other people may think about using PRT as a substitution for lightmapping - feasable, or am I missing something (I'm really not read up on PRTs as much as I should be)? Thanks very much for any insights! p.s. elaboration - what do I mean by fast for a process than can sometimes take 6-10 hours? 1 to 2 minutes is fast to me in a level that would normally take 15-30 minutes to compile a lightmap for. [Edited by - Dirge on September 23, 2005 2:39:13 PM]

##### Share on other sites
If 1 to 2 minutes is acceptable, couldn't you just provide different quality settings for the process? I seem to recall that, when building maps for quake 3, putting the resolution of the lightmap down (and possibly setting certain quality flags, I forget) could bring the compile time down from hours to minutes, or even less.

(EDIT: I should add that this was years ago, so my memory is a little hazy.)

[Edited by - MumbleFuzz on September 23, 2005 6:27:39 PM]

##### Share on other sites
Hi, what i do is give the user an option of lightmap sizes to start with.
Then for speed of generating the lightmap i skip every other texel.

eg 8x8 lightmap

calculate the first texel
copy that texel to the next texel. ie. texel 2
copy that texel to the next texel. ie. texel 4
...

This will give reasonable results if all youre looking for is someway to check the position of the light or the colour.

mark

##### Share on other sites
The nature of the algorithm you are using for lightmapping might also provide some shortcuts.

There was an article from the Garage Games guys on how to use hardware acceleration for lightmapping. They got pretty good results for their radiosity solver.

You can also tweak the quality settings to give you a "preview" mode, in which the lighting might not be incredibly accurate, but it would give you a good idea on how the final results might look like.

Another possibility would be parallelizing the lightmapper and run it on a render farm.

##### Share on other sites
Come to think of it, probably the most useful feature of the Quake tools in this respect was the ability to create 'regions': arbitrary sections of the map that could be compiled separately. The rest of the geometry was ignored. The artist could then compile - usually in seconds - only the section of the map that he was working on.

##### Share on other sites
Definitely use Radiosity. Although tesselating the scene and calculating the correct lightmap coordinates can be a pain (after a painful calculation of form-factors), the end result is very fast.

Of course, only if you dont want the shadows, because these take up the most of the time. Talking from my own experience with my radiosity calculator for our in-house editor, almost 100% results can be calculated almost instantly. The point is that you make only as much passes as there are lights. Our scenes with 500k-1000k patches and about 20-30 lights are almost real-time (1-2 seconds) to preview.
Of course, you dont get any color bleeding or shadows this way, but the end result is almost ideal and definitely good enough to be used in game (RPG-like dungeons).
The only thing you have to set up is the exposure, since relatively low amount of energy has been distributed. But you set this up manually anyway to see the meaningful results of your radiosity solver anyway, so that`s OK.

1. 1
2. 2
Rutin
19
3. 3
4. 4
5. 5

• 15
• 13
• 9
• 12
• 10
• ### Forum Statistics

• Total Topics
631442
• Total Posts
3000086
×