Author Topic: How do I create a sliced sprite with a zero percent transparency on the edge?  (Read 4199 times)

agentsmith666

  • Guest
I have a sliced sprite that I'd like the edge to be not "squared" off but ragged.  However when I import it into Unity the edges became white instead of transparent.  Do sliced sprites have to be completely filled in or can I create a custom edge?   


Custom edge sliced sprite:

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
White border is common in PNGs, since alpha of 0 in a PNG means "pure white" on the RGB channel. Try using the pre-multiply alpha checkbox on the atlas maker when updating this sprite. And if that doesn't fix it for you, either use Unlit/Premultiplied Alpha shader on the atlas, or Solidify A filter on the source texture in Photoshop. Search this forum for more info on that.

agentsmith666

  • Guest
"pre-multiply alpha checkbox on the atlas maker"  <--- I only see Padding, Trim Alpha, and Unity Packer. Trim Alpha is already checked.  I'm using a PSD file.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Then you don't have the latest version of NGUI and should update.