CIContext *context = [CIContext contextWithOptions:nil];
CIImage *inputImage = [CIImage imageWithCGImage:theImage.CGImage];
CIFilter *filter = [CIFilter filterWithName:@"CIGaussianBlur"];
[filter setValue:inputImage forKey:kCIInputImageKey];
[filter setValue:[NSNumber numberWithFloat:6] forKey:@"inputRadius"];
CIImage *result = [filter valueForKey:kCIOutputImageKey];
CGImageRef cgImage = [context createCGImage:result fromRect:[inputImage extent]];
returnImage = [UIImage imageWithCGImage:cgImage];
我是Objective C的新手。我不明白:“CGImageRef cgImage = [context createCGImage:result fromRect:[inputImage extent]];”这一行给出“exc_bad_access code = 1”错误。谢谢你的帮助。