Home Technical Talk

Padding bleeding onto uvs

polycounter lvl 9
Offline / Send Message
Chase polycounter lvl 9
From what I know about normal maps and baking 64 padding is the normal amount used. Im running into issues with details bleeding over onto other uvs. The only fix I can think of is to really space out the uvs but that seems illogical as it would have to be drastic to avoid this bleeding. If I use 4-8 I dont get this bleed over but I was told this 4-8 is onlg enough for 2 mip maps. Im assuming this bleeding is because my texture sheet is comprised of baked meshes and non baked meshes. So the baked uvs have nothing to pad against. Any idea on a work around? Based on the wiki I can use 4-8 padding especially cause im using udk. I can post the normal map if necessary

Replies

  • sargentcrunch
    Options
    Offline / Send Message
    sargentcrunch polycounter lvl 10
  • Chase
    Options
    Offline / Send Message
    Chase polycounter lvl 9
    Gotcha. So there's no way around having a texture sheet that combines baked/non baked with such a high amount of padding like 64 is what im seeing
  • sargentcrunch
    Options
    Offline / Send Message
    sargentcrunch polycounter lvl 10
  • Chase
    Options
    Offline / Send Message
    Chase polycounter lvl 9
    So just masking off the uv islands that I dont want the padding to effect in other words and erasing the bleed over in Photoshop?
  • Chase
    Options
    Offline / Send Message
    Chase polycounter lvl 9
    Selection map and deleting the padding thats bleeding in the unwanted areas worked. Im sure some will argue against this but show me another way haha
  • EarthQuake
    Options
    Offline / Send Message
    Yeah simply masking off is the easiest solution here.

    Another solution would be to bake without padding and then at the padding to everything after the maps are combined with the xnormal padding filter.

    Or just bake everything at once, why are you baking multiple maps in the first place?
  • Chase
    Options
    Offline / Send Message
    Chase polycounter lvl 9
    I wasnt baking multiple maps. Im just combining assets that will have baked normals with other meshes that arent being baked. The texture also has some tiling in it too. Just being efficient with it :D I thought there might have been some bad juju with masking the padding off later down the road. How much spacing between uvs do you need for 64 padding?
  • EarthQuake
    Options
    Offline / Send Message
    Oh ok that makes more sense. Yeah just mask the padding or do the padding all at once in post with the photoshop filter. If you're adding in extra elements the photoshop filter is probably best.

    There is no magic ratio of spacing to padding, this isn't really how it works. The problem is not a particular amount of spacing or a specific amount of padding, the problem is that you have uv elements that are not represented in the bake, so the padding algorithm has no knowledge of that and can't account for it. Generally, you can just crank padding to a crazy high number and you won't get overlaps if all your uvs are represented in your bake mesh. Normally this won't cause problems because the padding will stop when it hits something, but the thing you want it to hit isn't there.

    How much spacing between islands depends on your texture resolution more than anything.

    16 linear pixels at 4K mips to:
    8 pixels at 2K
    4 pixels at 1K
    2 pixels at 512
    1 pixels at 256
    0.5 pixels at 128

    Those are probably reasonable numbers.
  • Chase
    Options
    Offline / Send Message
    Chase polycounter lvl 9
    Oh gotcha. So I can have really packed uvs and use a high padding like 64? Just clarifying
  • EarthQuake
    Options
    Offline / Send Message
    Yes. You could use 1000 padding, as long as all your uv elements are represented at pad time you won't get any overlaps. I usually use like 64 or 96 or something pretty high to fill in all the empty spots. The only real drawback to using high padding is the time it takes to render the actual padding.
  • Chase
    Options
    Offline / Send Message
    Chase polycounter lvl 9
    Ok awesome sauce. As always youre a gentleman and a scholar Joe!
Sign In or Register to comment.