Hello Guest

Author Topic: Circular sprite - Outline appearing  (Read 3727 times)

cloudcamaleoniv

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 27
    • View Profile
Circular sprite - Outline appearing
« on: June 07, 2013, 10:18:02 pm »
Hello, I've got this problem before on a rectangular sprite, where all of the rectangle was filled by the image. I've had to duplicate that sprite to give a parallax sensation, but the sprite had that ugly thin black line.

All you've said to me was "Change the pad method to extend", and it worked great! Thanks for that.

Now I've got a very similar problem. I have to do some kind of a trail. The way I pictured it is creating a ball and duplicating it one after another, following the character.

Well... The outline is keeping me from getting a nice result. And I just can't get it off. Even with the "extend" thing, which I think it might work for full filled rectangle sprites. But what about a 'not-rectangle' one? As a circle? How can I do that?

Keeping in mind that... the "outline" are the alpha bits of the image, only visible when you put another very close to it (or if you have a very great eye). Not an actual outline.


Thanks man.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Circular sprite - Outline appearing
« Reply #1 on: June 07, 2013, 11:00:58 pm »
This is probably an issue with the source texture -

Premultiplied alpha will likely fix it.
Open the sprite collection editor, and in settings - tick premultiplied alpha and Commit.
After that, locate the atlas material, switch shader to tk2d/PremulVertexAlpha.

A more detailed explaination
http://unikronsoftware.com/2dtoolkit/forum/index.php/topic,189.0.html