I am making an talking pet app for iOS.
I wanna make warped image with xcode5.0, but I could not successfully. I have used such as following codes, but I am not sure it is right way for managing of image for animations.
UIImage * temp = [img resizableImageWithCapInsets:UIEdgeInsetsMake(offset_Y, 0.0f , 0.0f, 0.0f) resizingMode:UIImageResizingModeStretch];
CIImage * imgIN = [CIImage imageWithCGImage:temp.CGImage];
NSNumber *radius = [NSNumber numberWithFloat:5.0f];
NSNumber *scale = [NSNumber numberWithFloat:1.0f];
CGPoint point = CGPointMake(point1.x - self.frame.origin.x ,480 - (point1.y - self.frame.origin.y));
CIVector * center = [CIVector vectorWithCGPoint:point];
CIFilter * filter = [CIFilter filterWithName:@"CIBumpDistortion"];
[filter setValue:imgIN forKey:kCIInputImageKey];
[filter setValue:radius forKey:kCIInputRadiusKey];
[filter setValue:center forKey:kCIInputCenterKey];
[filter setValue:scale forKey:kCIInputScaleKey];
CIImage * filtOutImage = filter.outputImage;
CIContext * ctx = [CIContext contextWithOptions:nil];
CGImageRef createdImage = [ctx createCGImage:filtOutImage fromRect:filtOutImage.extent];
UIImage * finalImage = [UIImage imageWithCGImage:createdImage];
self.image = finalImage;
self.image = temp
IF you have experienced, please help me!!