Okay so yeah, I know how one would fix some of the lightmapping issues in Unreal 4 in relation to modular geometry and seams.
However I’m not sure how to find the functions within Unreal 4 if they exist.
Of coarse it will only work if we follow the base rules first , like setting up proper UV islands that are also snapped to a pixel grid like so …
I have a 128 x 128 UV unwrap here with all vertex snapped to pixel. Each face is snapped to 32 x 32 units. spacing is set to 10 units. ( plenty of room for baking Lightmaps , Yay!)
128 x 128 lightmap resolution set in Unreal 4 for the cube model.
Even with the above set up We get issues with the Lightmap density as shown in the screen below because there is some kind of padding around the whole lightmap texture or something, throwing off the alignment.
and the Lighting view!
So we counter balance this by changing the lightmap resolutionto 130 x 130…
You get the following screen when viewed with Lightmap Density! (since the Lightmap Density is equivalent to the pixels of a lightmap, everything aligns.
However!!! things are not so perfect in the world of real life. Just look at how much more worse that looks ! Ewwww Just Ewwww !
This happens because of the Lightmap pixel density is being aligned perfectly to the face of the polygon,The pixels are filtered to make things pretty, and the downside to that is having the pixels inside the polygon island blend with the “DIFFERENT COLORED” pixels outside the island.
The reason that the unaligned image looks better is because the pixels around the seams are cut in half to try and simulate a pixel color padding effect around the UV islands without actually adding real padding. both UDK and Unreal 4 add a extra pixel around the entire lightmap. (at least that’s what I think is happening)
Perhaps this was set up so that if a lightnmap texture filled the entire face of a polygon than you get the color pixel padding outside of the area to blend with so it appears seamless. Who knows?!
Here are my ideas to fix the seams issues for UV map islands…
A:
Have an option to Disable the filtering on the lightmap all togeather since the neibor pixels outside of the renderd UV island is blending with the pixels inside the UV islands of the lightmap.
Can this already be done ?!
B:
Use real pixel color Padding around the UV islands so that the pixels inside the UV island blend with pixels outside the island with the same colors.