简体   繁体   中英

Not losing resolution on ios screen snapshot

如果在拍摄视图快照时在以下功能中将缩放比例设置为2,在较大的设备(例如从iphonE 5到iphone 6+)上显示图像时,是否可以防止分辨率下降?

void UIGraphicsBeginImageContextWithOptions ( CGSize size, BOOL opaque, CGFloat scale );

是的,而不是将其硬编码为2,请使用[UIScreen mainScreen].scale

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM