View Full Version : [UV Tip] Packing of stepped/extruded objects

2013-09-23, 17:20
Packing of stepped objects for normal map baking workflow

This type of objects is seen very often, this should work for all extrusions pretty much, with some other points to note though. Im working with circular ones, because these ones are most problematic to pack well.
Anyway, this is what a typical extrusion looks like:

And this is lowpoly and highpoly separately:

Now, typically when packing UVs of the lowpoly, you need to put a seam at every hard edge, and account for the edge padding there, keeping a good distance between every two hard edges. So you would pack it like this: Imagine more edge padding, had to render it at pretty large resolution so its easy to see :) )

See how i had to scale the outer circular cluster to allow distance between it and the inner one?
Now, this doesnt look too bad, but if you have multiple extusions on top of each other, you are going to scale the outer ones way above their initial scaling, thus occupy more space, and you are going to waste loads of texels on padding between UV clusters.

Notice one thing, though: at seam between the two circles, normal map of both clusters turns the same color. So basically you can pack them much tighter, as you dont need to worry about pixel bleed. The reason why you add padding to seams (different colors) simply doesnt exist here. You can even put them right next to each other:


This way spend much less of your UV space on those clusters and the padding around them, making your UV maps better :)

One think you still need to consider, though. The colors on that seam needs to be same on all other maps as well, though. You need to think how the diffuse and specular will look there, maybe you cant pack it so tight after all.

2013-09-23, 18:08
Good tip lucky, I come across these a lot more than I expected. :-P In retrospect I guess some parts of my FMK could've been packed tighter.

Another thing to keep in mind for the rectangular bits; ideally the seam is out of sight from where the player is normally going to view it. For my detonator insert I chose the bottom.

Also, would this still work for an object space normal map?

2013-09-23, 18:22
Normals in this case are working much better than I would expect but wouldn't always be true and the bigger problem with grouping them up so close is diffuse/AO bleed between the two so I would pack like this, but I would keep a small gap between the two still but it can be smaller gap than for most other UVs :)