I draw an image with removable caps defined as follows:
[bubbleImg stretchableImageWithLeftCapWidth:17 topCapHeight:12]
And this works great when inside a UIImageView, but doesn't work when drawing an image like this:
CGContextDrawImage(context, CGRectMake(x, y, width, height), image.CGImage);
.. which I kind of suspected would not work. Is there a solution for stretch cover images when drawing in CG context?
source share