


But overall you will gain a tremendous speed boost.īut for our game this was not an option, since the game world is built in real-time by the player. You will also lose some space because your meshes will need lightmap UVs and get a bit bigger. The tradeoff here is that you will have to ship some extra lightmap textures, which will increase your build size and require some extra texture memory at runtime. Rendering things this way is fast because all the expensive and slow light calculations have been done offline, and at runtime the renderer (shader) just needs to look the result up in a texture. The renderer then knows where to make a model lighter or darker, creating the illusion of light. The process of light baking is the precalculation of highlights and shadows for a (static) scene the information for which is then stored in a lightmap. To avoid this you can bake every light that doesn’t cast realtime shadows. If you constantly push the hardware’s limits, the phone will run hot–and consequently, throttle down to protect itself. So, you don’t want to drain your users’ phone batteries more than necessary by having too many fancy lights in your scene.
