- Home /
Why aren't sprite pixels perfectly aligned on android?
I'm making a game with big pixels, I'm using 64 pixels per unit in the sprites and scale up 10 times. For the positions of gameobjects I'm making sure it's always a multiple of 0.15625 for the pixels to be aligned.
On PC it works perfectly, there are no gaps. But I just built for android and there's noticable gaps between pixels, my tile border sprite moves over a fraction to the bottom.
PC picture:
Android picture:
Pixel snap in the sprite material + a camera size script completely messes it up on PC, but solves most of the errors on android.
I just don't get it.
Answer by fusecore · Dec 13, 2014 at 04:50 PM
Turns out anything past two numbers after the comma gets discarded. I was using 6.4 pixels per points, so I was depending on 5 numbers after comma accuracy.