我对此感到奇怪,我已经在许多站点中看到描述了iPhone不支持Iphone上的Core Image滤镜的情况。但是我在Apple开发者网站的Core Animation示例页面中看到了Core图像过滤器。
只需在这里Iphone OS Reference Library看,您将在此页面上看到该示例
CIFilter *filter = [CIFilter filterWithName:@"CIBloom"];
[filter setDefaults];
[filter setValue:[NSNumber numberWithFloat:5.0] forKey:@"inputRadius"];
任何对此的描述将不胜感激。
最佳答案
Core Image在iPhone上不可用。从CATransition Class Reference谈起filter属性:
虽然CATransition类公开了
此属性,Core Image不是
在iPhone OS中可用。目前
此属性可用的过滤器
未定义。
另外,在CALayer Class Reference中,当谈论filter属性时:
虽然CALayer类公开了这一点
属性,Core Image不可用
在iPhone OS中。当前过滤器
可用于此属性的是
未定义。
正如Cory所指出的,该指南是为Mac编写的,并经过修改以适用于iPhone。不幸的是,他们留下了仅在Mac上可用的示例。
另请参阅问题:
关于ios - Iphone Core图像过滤器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2105475/