Download

Light bake anomaly

Any ideas on this light bake anomaly? I’ve tried everything. The geometry is definitely closed, have checked and triple checked. I’ve tried difference topology. No matter what, I get extra light bouncing around in this one particular corner piece (regardless of where it is placed). My lightmap UV islands also have plenty of padding, more than enough for the lightmap resolution - so it isn’t UV bleed.

Hi!

Are you keeping only the visible parts on your lightmap uv?
Can you show your lightmap uvs?
What is the lightmap resolution? …it looks low…

The highlighted island is the one causing the most problems. The resolution is set to 128, so there is ample padding. No matter where I place the wall, I get the same problem. I’ve worked with lightmaps a lot, never had a problem I couldn’t solve like this one.

The resolution should be fine:

UVres

What I would do is ditch all the hidden faces from the lightmap uv = they are not visible, no point of including them on your lightmap, they just take space away from the rest of the important/visible parts!
Then pixel snap all the island on your chosen resolution checkermap (-2 pixels depends on the engine version you’re using) with 4 pixel padding in the inner area.
This would be the best lightmap you can generate and should give you perfect results!
If you just drop your islands “randomly” with “random” paddings, onto a low res lightmap (like 128) then the areas that won’t match perfectly (as in this scene, you can see it on your lightmap density view) they will get an “inbetween” lighting information which is usually incorrect!
/+ …the way you build your scene (modular pieces on a continuos flat area) will produce (as you can see it here also) shading differences if your lightmass settings are low!/

Thanks for the feedback! Short answer: stop being lazy and make better lightmaps. So many wall pieces, so little time. :upside_down_face:

Do you know which version switched to the non (-2) pixel grid? I have my grid set to 64x64 in Modo - as in no extra pixels for import - and as far as I can tell, it seems to line up in 4.18+.

I’m all for cranking my lightmap resolutions, but when I’ve tried submitting marketplace assets in the past, I get rejected if everything isn’t in the ‘green zone’.

:smiley: I didn’t say that!! :smiley:
I know it’s a fuss but it’s worht it (saves time if you don’t have to hunt for these kind of lighting errors!)!
I think from maybe 4.19 or maybe 4.22, not sure… when Luoshuang “took over” and did adjustments to the lightmap calculation process at Epic… It used to add an extra 1 pixel “border” to all lightmaps! /when applying, it looked totally fine but after building lights they just shifted!/
I know nothing about the marketplace rules sorry! :S …I doubt though that for archviz projects the same rule would apply… BUT I can be wrong again! :wink:

:smiley: I didn’t say that!! :smiley:

Haha, just kidding. Appreciate the help. Gonna rebuild some lightmaps and run a test bake tonight.

Thanks!

尝试模型平滑组信息?

Hey Makigirl,

Been reworking my UVs. Just looking to clarify something you brought up. When adding the 4 pixel padding, I’d have to adjust my that depending on what resolution lightmap I was going to set in Unreal, right (vs what the pixel size my modeling software is using)? So, for a 64x64 lightmap, each gap should be 4/64 - if that makes sense? Makes for very small UV islands - and a lot of dead space!

Also, can I pack right to the edge of the UV space…or should I leave the 4 pixel gap around the edge too?

Hi!

First of all I forgot something earlier: if you make your lightmap on a 64 pixel checker map you can set your lightmap resolution in Unreal to 62 and it will work (if you use an older version engine! /it will add the 1 pixel border so it will become 64).

You can also try to create the lightmap in lower resolution (like 64) and it will be fine if you set it “doubled up” in Unreal engine! …but you will have more “unused” areas in those higher resolutions, since there you can leave just 2 pixels between islands… and this system won’t work backwards: if you create your lightmap on a higer res checker map, you can’t go lower in Unreal!

Also you can non-uniform scale (up to a certain amount, sometimes even extreme!) your islands to cover more area = more lighting detals.
Try to cover as much area as possible since the empty area is just a waste!
An island has to be at least 1 pixel, smaller ones won’t get lighting information!
Also if you have diagonal faces you can straighten it up!

If it’s a 64 pixel checker map then yes 4 pixels between islands. Same goes with 128 (4 pixels on a 128 checker map) and maaaybeee 256 but on higher ones you can leave just 2 pixels if I remember well! :S

In older versions you had to leave those paddings on the sides too but in later ones you can place them straight on the edge since the extra pixel won’t be added!

What I would do is create a simple box in your scene and test it with and/or without the border. After a fast light build you will see in the lightmap density view (check it before and after build) if it aligns perfectly(!!!) with your mesh!

/if your scene is huge, for the test build I would apply a really low lightmap (override in the main editor area and not in the mesh’s properties one by one) resolution (like 4 or 8) to all other meshes to speed up the test build! …you can also use this methode if you have a problematic mesh and want to see the lighting result fast! When you solved the issue just untick the overrides and you will get your normal scene back/

I feel like I forgot something that I wanted to say… :S

Thanks, Makigirl! This is really great info! From my tests, it seems 4.18 is shifting my lightmaps.

I’ve been working in a lower version of UEas assets aren’t backwards compatible - so I have to work in whatever the lowest version is that I want to be marketable to. I used to work in 4.10 - but that was creating too many headaches!

However, the majority of users will be using a later version, which means I need to work in 4.18 and then check my lightmaps later versions. Will be testing that tonight, my lightmaps should all be working now in a ‘non-shifting’ engine. And the little bit of shift I’m getting is much better than it was before.

And good news! My initial issue that started all this has been resolved! And I think this scene is looking pretty good for having been built with shifting lightmaps and resolutions all set at 128 or lower.

Thanks for taking the time to share your knowledge.

I’m glad it worked out for you and the problem is gone!
Your scene looks nice!!