Author Topic: Sprite alpha weird lines on different atlases  (Read 2076 times)

dino000

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 2
    • View Profile
Sprite alpha weird lines on different atlases
« on: January 03, 2016, 10:55:25 AM »
Hi!

I'm using NGUI 2.7.0 with Unity 5.

I have two different atlases with the same sprite.
When I use one of them the sprite looks ok, but when I use the other one the sprite has some weird lines on it's alpha part.
You can see the problem here: http://postimg.org/image/vs7lzb6it/

I read some advice about increasing the canvas around the image for like 1-2 pixels. It seemed like it helped. But now it's happening again on the other atlas.
Both atlases have the same settings and UISprite scripts have the same settings too.

Any ideas? Thanks for reading.

dino000

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 2
    • View Profile
Re: Sprite alpha weird lines on different atlases
« Reply #1 on: January 05, 2016, 01:22:04 PM »
I've finally found a solution. So in case anyone needs it in the future:

- Shader of Material of Atlas must be Unlit/Transparent and sprites have at least 1 px of alpha around the edges.
- After material shader change just go to atlas, choose random material and switch back to it's original material