我需要释放从UIGraphicsGetCurrentContext()返回的上下文吗? [英] Do I need to release the context returned from UIGraphicsGetCurrentContext()?

查看:647
本文介绍了我需要释放从UIGraphicsGetCurrentContext()返回的上下文吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 CGContextRef

UIGraphicsBeginImageContext(self.drawImage.frame.size);
CGContextRef context=UIGraphicsGetCurrentContext();
CGContextSetRGBStrokeColor(context,0.0f,0.0f,0.0f,1.0f);
UIGraphicsEndImageContext();
CGContextRelease(context);

我需要调用 CGContextRelease(Context);

推荐答案

否。请参阅创建规则

这篇关于我需要释放从UIGraphicsGetCurrentContext()返回的上下文吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆