Lightmaps causing strange results

I can’t seem to get the materials to show up properly, and I suspect it might have something to do with my lightmaps. They do begin to look better as I increase the lightmap resolution on them, but I don’t think I need to get to 1024 on a tiny door lock for it to display properly.

The handle below has a strange blockiness to the chrome material.

Here is a shot of it in the static mesh editor with the UV channel displayed. It looks great in here…

Here is the door lock.

And here in the editor.

Anyone have any ideas on this?

You need to actually check Channel 1 instead of 0 for lightmaps.
In case you dont have one, just click “generate lightmaps UV’s” and press apply.
the way its set now is that it will look at channel 0, and use those islands to create a lightmap uv for channel 1.

alternatively set “Lightmap coordinate index” to zero.
(but only if there are no uv’s mirrored/outside of 0-1 space or overlapping).

Sorry, I should have been more clear. I already have my own light map that I created in 3DS Max. I unchecked “Generate Lightmap UVs” when I imported the mesh with two UVs, and I’ve checked both map channels (which are the same) so I know it’s identifying and using the right one.

Despite all this, the model still appears strange depending on the resolution of light map that I use. I rearranged my light map UVs a bit to add more spacing, but that hasn’t helped with the lock.

For example, below is the door lock at 128 light map resolution. You can see the layered banding around the latch mechanism. I don’t see how that can possibly be, especially considering the layout of the UVs.

When I increase the resolution to 1024 (a ridiculous resolution for an object this small and insignificant), it looks somewhat better, but there are still strange hard edges on the right hand side. See below.

Here is a look at the static mesh editor and the light map UVs.

Bonus question: What is the difference between Min Lightmap Resolution in the LOD0 pane and the Light Map Resolution in the Static Mesh Settings pane?


Let me answer the bonus question first:
The “Min lightmap res” in LOD0 is mostly used for generating the lightmaps, when you generate the lightmap UE4 will add a one pixel buffer on each side to make sure there is (almost) no light/shadow bleeding on the lightmap.
So if you set the “min lightmap res” it will create a one pixel buffer as if the lightmap resolution is 64x64 pixels.
(So if the lightmap resolution in the static mesh settings panel is 128, there will be a 2 pixel buffer on each side)
(But if you then set the lightmap resolution to 32x32 you only have half a pixel buffer and it could probably mess up and cause shadow/light bleeding)

this also sort of explains something about lightmaps. even though your lightmap is 128 (so 128x128 pixels) your uv-islands only use a few pixels of that lightmap. and each pixel can only contain one value. so if your uv-island only uses 16x16 pixels that means that there are only 256 pixels used for that piece.
And looking at your lightmap uv’s, some objects use even less.

You can set the “Min lightmap resolution” to the minimum you want it to use, then in “source lightmap index” select the lightmap channel you already made. (channel 1), make sure the destination is also channel 1, activate “generate lightmap uv’s” and press “apply changes” this way UE4 will use your created lightmap UV’s, rearranges/resized them and will do its best to make it as optimal as possible.

Also if you weld the small ledge to the cylinder behind it (so its one object) it will significantly increase the quality of the lightmaps as it doesnt need to generate the shadow on the polygons currently partially covered by the ledge.

Hope that helps.

Thank you for answering that. My problems never seem to end though.

I adjusted my door so that the front panel has the largest UV island. This is because I want the shadow from the handle to look sharp. However, as you can see from the photo below, I still have strange banding and shadows similar to the door lock earlier. The door handle is still messed up too (can’t seem to fix that no matter what I do). The door has a 1024 light map resolution.

There’s got to be some setting that I’m not seeing that is causing this. Below is the static mesh editor for the door.

Im having the same issues as jeffym85. I have tried tons of different meshes and it seems to happen more on smaller objects. This only seems to be an issue with me since i upgraded to 4.9. Ill keep testing and see if i cant come up with a solution!


So, after messing around for the past hour, i found that if you change your directional light to Static or moveable it fixes the issue, if you put it to station the artifacts/banding comes back. Hope this helps someone!