I have a problem. When I use "renderInContext" on the iPad, the used memory is never released or accumulated until the application closes with "Memory Warning" Level = 1 and Level = 2
My code is:
CGRect mediaBox = CGRectMake(0, 0, 16.54 * 72.0, 24.02 * 72.0); CGContextRef ctx = CGPDFContextCreateWithURL((CFURLRef)[NSURL fileURLWithPath:posterPath isDirectory:NO], &mediaBox, NULL); CGPDFContextBeginPage(ctx, NULL); CGContextScaleCTM(ctx, 0.516, -0.516); CGContextTranslateCTM(ctx, 0, -mediaBox.size.height - 1500); [[self returnBigView].layer renderInContext:ctx]; CGPDFContextEndPage(ctx); CGPDFContextClose(ctx); CGContextRelease(ctx);
I tried several ways, but without free memory. Any ideas?
** Sorry for my bad english
source share