NSData and UIImage

后端 未结 5 1956
孤独总比滥情好
孤独总比滥情好 2020-12-13 03:51

I am trying to load UIImage object from NSData, and the sample code was to NSImage, I guess they should be the same. But just now load

5条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-13 04:16

    UIImage has an -initWithData: method. From the docs: "The data in the data parameter must be formatted to match the file format of one of the system’s supported image types."

提交回复
热议问题