Getting Started
...
Glossary
H-M Terms

Lightmap

3min

A lightmap is a texture that stores the lighting information for a scene. It is a two-dimensional image that is used to calculate the color of each pixel on a 3D object.

Lightmaps are often used in real-time games to improve the performance of the lighting system. This is because lightmaps can be pre-computed and stored in memory, which allows the game engine to quickly calculate the lighting for each object in the scene.

There are two main types of lightmaps: baked lightmaps and dynamic lightmaps. Baked lightmaps are created by rendering the scene from the perspective of each light source and storing the resulting image as a lightmap. Dynamic lightmaps are updated in real time as the game is played, which allows the lighting to change as the player moves around the scene.

Here are some of the benefits of using lightmaps in game development:

  • Improved performance: Lightmaps can improve the performance of the lighting system by reducing the number of calculations that need to be performed.
  • Pre-computed lighting: Lightmaps can be pre-computed and stored in memory, which allows the game engine to quickly calculate the lighting for each object in the scene.
  • More realistic lighting: Lightmaps can help to create more realistic lighting by providing a more accurate representation of the light sources in the scene.

Here are some of the drawbacks of using lightmaps in game development:

  • Static lighting: Lightmaps cannot be used to create dynamic lighting effects, such as shadows that move as the player moves around the scene.
  • Limited detail: Lightmaps can only store a limited amount of detail, which can lead to a loss of realism in the lighting.
  • Increased file size: Lightmaps can increase the file size of the game, which can impact loading times and performance.

Overall, lightmaps are a powerful tool that can be used to improve the performance and realism of the lighting in games. However, it is important to be aware of the potential drawbacks of lightmaps, such as static lighting and increased file size.

Here are some additional tips for using lightmaps in game development:

  • Use a high quality lightmap baker: There are a variety of lightmap bakers available, each with its own advantages and disadvantages. Choosing a high quality lightmap baker can help to improve the quality of the lightmaps.
  • Use a low lightmap resolution: Using a low lightmap resolution will reduce the file size of the lightmaps, but it will also reduce the quality of the lighting.
  • Use a high lightmap resolution: Using a high lightmap resolution will increase the file size of the lightmaps, but it will also increase the quality of the lighting.
  • Experiment with different lightmap resolutions: Experimenting with different lightmap resolutions can help you to find the right balance between file size and quality.

Feedback

Please be sure to submit issues or feature requests through the embedded feedback form. In the event it is a major issue please contact us directly through Discord.

Updated 03 Apr 2024
Doc contributor
Did this page help you?