Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am new to Unity. I'm trying it out and using Futile for a code-first approach, but still importing textures using the Unity system.

The problem I'm having is that when I use mip maps to scale large sprites down to smaller sizes without jagged edges, I'm getting a black line artefact above said sprites.

Hard to see

A little hard to see, but they're there. If I turn down the resolution, you can clearly see them:

Easier to see

These are my texture settings:


My question is, why are these black lines here? Is it a mistake I've made? Is it just a common side effect? How can I reduce these? Also, if this is the wrong approach, how can I use smooth sprites in a game with the ability for them to scale up smoothly?


share|improve this question
you are using an atlas, aren't you? – Heisenbug Apr 25 '13 at 15:49
up vote 9 down vote accepted

There are many reasons why you may be getting those lines. I wrote a more detailed answer in here, but the bottom line is:

Do not do atlasing and mipmapping at the same time.

For 2D, in general, you don't want/need to do mipmapping. That's useful mostly in 3D where you don't know the size at which your textures will be rendered, but that's usually uncommon in 2D.

If you definitely have a texture that you will aggressively downscale, then don't include it in an atlas.

And I'd also recommend you turn anisotropy off. That's meant to give you better results when you're looking at big textures from extremely sharp angles, which simply doesn't happen if your game is 2D.

share|improve this answer
actually a proper padding should allow atlas and mipmap to be used together, am I wrong? +1 btw – Heisenbug Apr 25 '13 at 15:57
@Heisenbug by adding padding, all you're doing is moving the problem to a lower mip level. If you must have mipmaps and atlases, then consider creating them manually, and only down to the level where your smallest object is 1x1 pixel. But in 2D you usually don't downscale textures enough to require mipmapping, so I'd certainly recommend you don't mix atlasing and mipmapping. – Panda Pajama Apr 25 '13 at 16:03
Thanks, informative answer, exactly what I needed. – Adam K Dean Apr 26 '13 at 10:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.