jpg or png for UIImage — which is more efficient?

后端 未结 7 1609
刺人心
刺人心 2021-02-06 04:35

I am grabbing an image from the camera roll and then using it for a while as well as save it to disk as a PNG on the iPhone. I am getting the odd crash, presumably due to out of

相关标签:
7条回答
  • 2021-02-06 05:12

    I don't have any hard data, but I'd assume that PNGs are preferable because Apple seems to use PNGs virtually everywhere in iPhone OS.

    However, if you've already got the code set up for writing PNGs, it shouldn't be too hard to change it to write JPEGs, should it? Just try both methods and see which works better.

    0 讨论(0)
提交回复
热议问题