Search Unity

White line between objects

Discussion in 'General Graphics' started by FinnanKeily, May 23, 2020.

  1. FinnanKeily

    FinnanKeily

    Joined:
    May 23, 2020
    Posts:
    3
    When I have two objects next to each other, there is a white line between them. How do I fix this? I have already tried disabling Anti Aliasing but that has not worked. By the way, I'm very new to Unity so I may not understand a few of your solutions...

    upload_2020-5-23_16-46-56.png

    upload_2020-5-23_16-48-9.png
     
  2. richardkettlewell

    richardkettlewell

    Unity Technologies

    Joined:
    Sep 9, 2015
    Posts:
    2,285
  3. FinnanKeily

    FinnanKeily

    Joined:
    May 23, 2020
    Posts:
    3
    I feel like an absolute genius - I fixed it by myself after looking everywhere and finding nothing!

    I basically set the Texture Type to 2D (Sprite and UI) and set Extrude Edges to 0 on my PNG file. Very proud of myself. :)

    upload_2020-5-23_23-5-9.png
     
  4. FinnanKeily

    FinnanKeily

    Joined:
    May 23, 2020
    Posts:
    3
    Weird. I just changed it back to 1 and the bug is not there anymore.
     
  5. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,342
    Looking closely at the screenshot you posted I noticed there's a line in this image too:
    upload_2020-5-24_0-30-25.png
    To me that makes me think there's probably a very thin 1 pixel outline in your texture, maybe a small amount of unintended transparency. If you scaled these up or down in Photoshop, it likes to ever so slightly blurred opacity in the edges of your layer which when imported into Unity will cause there to be a slightly white edge to your textures (blame Adobe, according to them this is the "correct" behavior).