如何在 iPhone Objective C 中映射设计
我有一个问题,假设我有 1 个 png,其背景是透明的,并且所有自定义设计都是他们的假设:http://www.creativetechs.com/iq/tip_images/iPhoneElements-Yahoo.png
我希望我在代码中添加了 png 以及如何获取坐标并实现这些图像坐标到 UIImageView 中,当它运行时,它可以从 png 中获取这些坐标并映射设计。
我知道他们可能有一些软件可以提供这些坐标的 plist,然后映射它,请任何人指导我。谢谢。
i have a question that suppose i have 1 png which background is transparent and all the custom design are their suppose this: http://www.creativetechs.com/iq/tip_images/iPhoneElements-Yahoo.png
i want that i have add the png in my code and how could i get the cordinate and implement those images cordinate into UIImageView and when its run the it can grab those cordinate from the png and map the design.
I know its possible their is some software which can give the plist of those cordinate and then map it please any one guide me. Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
此问题/答案解释了如何创建子图像:
从 UIImage 返回子图像
我建议将坐标存储在 plist 中(正如您所建议的)并使用上述方法从您的精灵表中创建每个子图像。
(代码来自上面的帖子)
This question/answer explains how to create the subimage:
Return a subimage from a UIImage
I would suggest storing the coordinates in a plist (as you suggested) and using the above method to create each subimage from you sprite sheet.
(code from the above post)