UIImageView 渲染图像与原始图像不同
右边的图片是我用photoshop制作的。然后,我剥离所有文本并将其放入图像视图中,一旦我这样做,颜色就会发生变化,并且垂直线会失去清晰度。还有其他人遇到过类似的问题吗?我该怎么办? 替代文字 http://grab.by/1DuZ
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
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
尺寸是否正确?图像的位置是整数吗?如果这些情况,抗锯齿会使图像稍微模糊。
Are the dimensions correct? Is the position of the image an integer? If these cases antialiasing will slightly blur your image.
需要注意的一件事是,如果您的图像在任一维度上都是奇数个像素,那么将其在屏幕上居中将导致其未对齐。想象一下,如果您有一张 1x1 图像(只有一个像素)并尝试将其在屏幕上完美居中。这是不可能的,因为屏幕的宽度和高度都是偶数个像素。这就是为什么最好尽可能使用均匀尺寸的图像。
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.