Some parts have been separated and are given enough padding between the other charts to ensure fewer artifacts or light leaks. When the lightmap is laid out (right), all faces are represented with their own UV space so that a proper light bake can be generated. This enables space to be used efficiently for a single texture that is mapped to all faces without having to use a higher resolution due to less texel density. Instead of using UV space for each side, a single texture has been created and each side's UV charts have been laid on top of one another. It's acceptable for them to have islands that are overlapping or even wrapping, because you can have tiling textures or ones assigned to different parts of the geometry.įor example, the building facade below has four sides that have the same texture mapped to its different faces. Setting up a texture UV doesn't have these stipulations because it only matters how you want the texture mapped to those UV charts.
Lightmaps must be laid out flat without any overlapping areas and they need enough padding between each UV chart to ensure that there isn't any light leaking. Setting up a texture UV often requires a different approach to laying out the UV charts to get the best result than how you would for lightmap UV. If you'd like to jump ahead, you can see the Contiguous UVs and Padding section of this page. Later parts of this page will cover the basics unwrapping UVs to get specific results and this is a process that can be combined with auto-generate lightmaps.
#Shadow complex map wont update software
Keep this in mind when creating lightmap UVs and by doing a little bit of upfront work in your modeling software or UV editing software, you can get a good result by splitting the UV charts before import into UE4. The algorithm repacks the UV charts from the specified source lightmap index but does not cut or split them in the process.
The tool uses a repacking algorithm to generate the lightmap based on a Source Lightmap Index (or UV channel) and then stores it in a new specified by the Destination Lightmap Index. These settings can be used at any time to generate a lightmap UV or repack existing ones. Once a lightmap UV has been generated for a static mesh, it can be adjusted in the Static Mesh Editor, using the lightmap generation settings in the Details panel Build Settings, but there is no requirement to ever touch these settings once the lightmap UV has been generated. The generated lightmap UV repacks the islands so that they meet the requirements of a good lightmap with no errors: no overlapping or wrapping islands, and enough padding between islands to limit artifacts based on the targeted lightmap resolution. When importing your own assets, a lightmap UV will be generated for you automatically (unless disabled) in the FBX Import Options window.Ī lightmap will be automatically generated based on the UV for the texture layout (UV channel 0). We've adopted this process into our own workflow here at Epic. Using Unreal Engine 4's Lightmap Auto-Generation toolĬreating a custom one with UV editing toolsĬreating custom lightmap UVs can be a time-consuming process, especially if you have projects requiring thousands or ten of thousands of assets. An auto-generated lightmap can be a quick way to pack a lightmap UV to save you a significant time investment of manually setting one up and padding it correctly. There are two ways you can create a lightmap: If your game or project only uses dynamic lighting, there is no need to set up lightmaps for each static mesh. Lightmaps are only required when a static mesh will be lit using any form of baked (or precomputed) lighting. The process of lightmapping is one of the more challenging areas of environment art creation because, unlike texture UVs, each face of the model needs to have its own unique space on the lightmap with no overlapping faces, and UV charts need to ensure that there is enough padding (or spacing) between them to avoid artifacts. This UV is called a Lightmap UV, which is similar to a texture UV in that it consists of laid-out UV charts (or UV islands) that are unique to each static mesh except this particular UV is used to store baked lighting and shadow information. If your project intends to use any form of baked lighting (static or stationary), you will also need to set up a UV channel that stores lighting information.
When creating assets for your game, you will often go through the process of setting up a UV that is laid out for your textures. Directly Lit Areas with Increased Lightmap Resolution