随笔分类 -  图形图像

摘要:圆角图片因为GPU渲染会影响性能参考:http://www.cocoachina.com/ios/20150803/12873.htmlhttp://blog.sina.com.cn/s/blog_671d2e4f0101cxpl.htmlhttp://www.cnblogs.com/thefee... 阅读全文
posted @ 2015-09-24 18:04 幻想无极 阅读(672) 评论(0) 推荐(0)
摘要:1、CAShapeLayer继承至CALayer,可以使用CALayer的所有属性值2、CAShapeLayer需要与贝塞尔曲线配合使用才有意义3、使用CAShapeLayer与贝塞尔曲线可以实现不在view的drawRect方法中画出一些想要的图形4、CAShapeLayer属于CoreAnima... 阅读全文
posted @ 2015-07-23 12:11 幻想无极 阅读(203) 评论(0) 推荐(0)
摘要:self.view.backgroundColor=[UIColorblackColor];//获取图片self.imageContents=[UIImageimageNamed:@"原始图片"];self.maskContents=[UIImageimageNamed:@"maskLayerCon... 阅读全文
posted @ 2015-07-23 10:10 幻想无极 阅读(1905) 评论(0) 推荐(0)
摘要:#import"ViewController.h"@interfaceViewController()@property(nonatomic,strong)CALayer*imageLayer;@end@implementationViewController-(void)viewDidLoad{[... 阅读全文
posted @ 2015-07-21 23:52 幻想无极 阅读(2750) 评论(0) 推荐(0)
摘要:/*** 用CALayer定制下载进度条控件* 1.单独创建出CALayer* 2.直接修改CALayer的frame值,执行隐式动画,实现进度条效果* 3.用定时器(NSTimer)模拟网络下载时提供的百分比数据* 4.将CALayer封装进UIView子类中定制进度条控件*/自定义一个UIVie... 阅读全文
posted @ 2015-07-21 23:03 幻想无极 阅读(2149) 评论(0) 推荐(0)
摘要:转自: http://www.cnblogs.com/pengyingh/articles/2381673.htmlUIView与CALayer的区别,很详细 研究Core Animation已经有段时间了,关于Core Animation,网上没什么好的介绍。苹果网站上有篇专门的总结性... 阅读全文
posted @ 2015-07-21 22:46 幻想无极 阅读(217) 评论(0) 推荐(0)
摘要:扩展:https://github.com/lichtschlag/Dazzle //创建出LayerCAEmitterLayer*emitterLayer=[CAEmitterLayerlayer];//显示边框emitterLayer.borderWidth=1;//给定尺寸emitterLa... 阅读全文
posted @ 2015-07-21 12:19 幻想无极 阅读(704) 评论(0) 推荐(0)
摘要:UIImage*showImage=[UIImageimageNamed:@"demo.jpg"];CGRectrect=CGRectMake(0,0,showImage.size.width,showImage.size.height);//获取OpenGLES需然然的上下文EAGLContext... 阅读全文
posted @ 2015-07-21 11:58 幻想无极 阅读(578) 评论(0) 推荐(0)
摘要:CoreImage是一个图像框架,它基于OpenGL顶层创建,底层则用着色器来处理图像,这意味着它利用了GPU基于硬件加速来处理图像。CoreImage中有很多滤镜,它们能够一次给予一张图像或者视频帧多种视觉效果。而且滤镜可以连接起来组成一个滤镜链,把滤镜效果叠加起来处理图像。CoreImage框架... 阅读全文
posted @ 2015-07-21 01:05 幻想无极 阅读(1335) 评论(0) 推荐(0)
摘要:现在很多滤镜效果都写好了,搬运工的我直接拿来用(感谢🙏贡献源码的大神些):http://code.cocoachina.com/detail/302762/%E7%85%A7%E7%89%87%E7%BC%96%E8%BE%91%EF%BC%88%E6%BB%A4%E9%95%9C%EF%BC%... 阅读全文
posted @ 2015-06-25 01:26 幻想无极 阅读(716) 评论(2) 推荐(0)