问题
The image on the right is the one that I produced in photoshop. I then stripped all text and put it in an image view, as soon as I did that there was a change in colour and the vertical line lost it sharpness. Has anyone else run into a similar problem? What do I do? alt text http://grab.by/1DuZ
回答1:
Are the dimensions correct? Is the position of the image an integer? If these cases antialiasing will slightly blur your image.
回答2:
One thing to be careful of is that if your image is an odd number of pixels in either dimension then centering it onscreen will cause it to be misaligned. Imagine if you had a 1x1 image (just one pixel) and tried to center it perfectly onscreen. It can't be done because the screen is an even number of pixels wide and high. This is why it's best to always use even dimensioned images whenever possible.
来源:https://stackoverflow.com/questions/2034016/uiimageview-renders-image-differently-to-original