UITableView Cell 的图像发生变化?
当我完成了应用程序内购买应用程序的开发后,在 iPad/Iphone 上进行了多次测试后,一切都很好,表格视图单元格的图像及其高度与代码中所写的完全相同,因此我上传了该应用程序,当它出现时被处理到应用程序商店,我下载了它,iPhone/iPad 中的表格视图单元格的尺寸不同,比测试时设置的尺寸大得多,所以单元格中的图像就像拉伸了!!!并且不清晰,我尝试直接通过测试它xcode 到我的设备,它几乎像以前一样好,但问题是只有当从商店下载时,
我真的很感谢任何帮助,
问候,
While i finished developing an in-app-purchase application, and after several testing on iPad/Iphone, every thing was fine, the images of table view's cells and its hight was exactly as wrote in code, so i upload the application, when it was processed to the app Store, i download it, the table view cells in both IPhone/IPad were in different sizes much bigger size then that was set while testing,so the image in cells was like stretched!!!!and not clear, i tried to test it then directly via xcode to my device, it was almost fine as before, but the problem is only when downloading from store,
I really appreciate any help,
Regards,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这很可能与浮点计算优化有关。
当构建发布时,默认情况下,Xcode 将尝试完全优化您的代码,包括使您的浮点计算更加高效。然而,有时它们可能会被错误地优化,这可能会导致重大问题,特别是在视图的定位/大小调整等方面。
对我来说,这种情况发生在构建发布+armv6架构时,我已经有了 之前完全相同的问题(仅在发布时才实现)。
值得庆幸的是,有一种方法可以禁用浮点优化。操作方法如下:
使用 LLVM GCC 4.2
Targets
下的项目名称(如下所示),然后单击“Build Settings” 。Apple LLVM 3.0 编译器
-mno-thumb
。现在应该如下所示如果此后在发布版本下仍然存在问题,您可能想尝试全局禁用拇指编译。
希望有帮助。
This is quite likely to be do with floating-point calculation optimization.
When building for release, by default, Xcode will try to fully optimize your code, including making your floating-point calculations more efficient. However, sometimes they can be incorrectly optimized, and this can cause major issues especially with positioning / sizing of views etc.
For me, this happens when building for release + armv6 architecture, and I've had exactly the same problem (only realized when released) before.
Thankfully, there is a way to disable the floating-point optimizations. Here's how:
Using LLVM GCC 4.2
Targets
(as seen below), then click "Build Settings".Using Apple LLVM 3.0 Compiler
-mno-thumb
. It should now look like belowIf it still has issues under the release build after that, you may want to try disabling compile for thumb globally.
Hope that helps.