Baking lightmaps seem to break normal maps on materials

Hi,

I’m getting some odd behaviour when baking lightmaps in my scene. Here are two entities using the same model and material side by side, the one on the left has baked lightMaps enabled.

It seems like the normal maps is ignored? The result is even stranger when I apply a heightMap: (lots of black areas around the edges of the mesh)

Here is a link to the project if that helps.

Would really appreciate any help or ideas!

Thanks,
Ben

It’s tricky to get high quality baked light that uses normal maps and looks right.

I set it up here:
I tried something here: https://playcanvas.com/project/1349174/settings

  • directional light set up to bake direction
  • cube set up to baked as well
  • its material has normal map, but also specular->metalness set to true, as this seems to only work in metalic workflow. Metalness is dialed down, so it does not look like metal.
  • There is also a skydome in the scene, but in the Lightmapping settings, Ambient baking is off … so this one is realtime with normal maps

disable the directional light to see ambient contribution, and also dial skydome intensity to 0 to see directional only.

-Heightmap is really old style and I would not bother. We have plans to replace it by something different, as that is not useful at all.

One option is to just bake AO map in Blender or similar, and use real time lighting here. Or even try SSAO.

Hi @mvaligursky, thanks for the tips!

Our scene has a lot of swappable pieces so pre-baking AO maps wouldn’t work for our needs. We have also tried SSAO but it was a pretty big hit to performance.

I managed to find a solution by only using baking for AO in the scene, then setting each light to affect lightmapped entities (though they don’t bake), with the shadows set to only update whenever we run a new bake.

1 Like