Search Unity

Normal Map Artifacts Issue

Discussion in 'General Graphics' started by gamedivision, Jun 24, 2017.

  1. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    as you can see by the image the normal map is very clean and straight but when i import it into unity i get this type of blocking on it and I'm not sure why I've tried png,jpg,targa its the same but slightly different for each
     
  2. theANMATOR2b

    theANMATOR2b

    Joined:
    Jul 12, 2014
    Posts:
    7,790
    That is a very clean normal map.
    I don't think the artifacts are from the normal map.
    Probably from the lighting/shadows, or possibly the spec map.

    Question: Will the user ever get THIS close to that object? If not move back to where the user will normally view the object from - does the artifacts persist?

    Alternately you can edit shadows and lighting to fit this close view position.
     
  3. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    thanks for the reply the user is going to be very close to that particular object and what you see there is the grey colormap and the normal map I've removed the colour so the normal map is just by its self and the artefacts are still there im just not sure what's causing it .
     
  4. theANMATOR2b

    theANMATOR2b

    Joined:
    Jul 12, 2014
    Posts:
    7,790
    That has to be lighting/shadows then - right?
    What is the overall resolution of the normal map and viewport resolution settings in Unity?

    What are the import settings of that map?
     
  5. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    2048 x 2048 png but I've tried all other formats
     
  6. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    texture quality is set to full in unity
     
  7. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,348
    Those artifacts are absolutely from the normal map. The model your using to bake the normal map's from has a very gentle curve to the "flat" area, and you're seeing the limitations of an 8 bit per channel normal map accentuated by compression.

    Take that normal map image into a graphics program like Photoshop or Gimp and increase the contrast and you'll start to see those boxes show up.

    The solutions to this would be to fix the original model to actually be perfectly flat, or just modify the texture manually.
     
  8. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    that can't be true i used nDo to create the normal maps so i didn't bake the normal map at all
     
  9. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,348
    Might not be baked from a mesh, but the normal map is still not perfectly flat. I can see the larger squarish artifacts in the normal map texture just by looking at it. Not sure what is causing it in nDo, best guess is you've got a layer with a very high softness and low opacity?
     
    theANMATOR2b and gamedivision like this.
  10. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    thanks man ill give it try
     
  11. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    re creating another normal map worked thank you for pointing me in the right direction
     
  12. gamedivision

    gamedivision

    Joined:
    Nov 4, 2012
    Posts:
    47
    this is the official response from quixel

    The issue you're seeing there most likely results from using an 8-bit normal map with softness settings that are too large to support the shape. You would need to author 16-bit normals to create soft details like that without artifacts or banding being introduced. You would also need to maintain 16-bit in the engine for the normals to not start banding again. This is a limitation of 8-bit textures and there's really not much you can do about it beyond designing textures to fit the bit-range you're working with, unfortunately.
     
  13. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,348
    Yep, so basically what I said.

    16 bit normals are possible in Unity, but not straightforward to implement since none of the built in shaders can use them as Unity doesn't have support for importing 16 bit textures as "normal maps". It would require special handling of your normal map texture assets and all custom shaders.