Closed ghost closed 10 years ago
Hi @stickytroll, thanks for the report. I suspect the calls to UIGraphicsBeginImageContextWithOptions()
and UIGraphicsGetCurrentContext
are failing, possibly a bug in UIKit.
I need to switch over to using CGBitmapContextCreate().
@stickytroll, have you checked that self.convertButton.frame.size
is non-zero?
Hi, yes the frame size is non-zero. The image is being created (and cached) at the correct size of the button's frame.
Hi. I've made some changes to the code. Can you see if you still get the error?
The latest code seems to be working fine, without any warnings... What was the issue?
My guess is that UIGraphicsBeginImageContextWithOptions()
was failing, so I replaced it with the Core Graphics equivalents. I've also added more parameter validation.
Thanks for your help ;-)
I noticed this had been raised in February but then closed in March unresolved.
I'm getting this warning in Xcode console: