自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(7)
  • 资源 (3)
  • 收藏
  • 关注

转载 cast of Objective-C pointer type 'NSString *' to C pointer type 'CFStringRef' (aka 'const struct __C

第一步:第二步:http://stackoverflow.com/questions/6725558/cast-of-objective-c-pointer-type-nsstring-to-c-pointer-type-cfstringref-aWhen converting an Objective-C progr

2017-05-20 10:58:30 2882

原创 iOS 处理中文网址路径转换

今天处理图片加载和文件下载的时候发现一个问题,服务端返回的url里面含有中文,使用[NSURL URLWithString:urlString]生成URL对象时,iOS客户端不能正确进行网络请求,网上找到的URLEncode方法又不能完全解决问题.   方法1:NSString* encodedString = [urlStringstringByAddingPercentEscapesU

2017-05-20 10:24:28 1594

原创 iOS_隐藏顶部状态栏方式

iOS 6通过[UIApplication sharedApplication] 取得app的单例,然后调用setStatusBarHidden方法隐藏 Status Bar。iOS 7Info.plist不但要在Info.plist中增加 Status bar is initially hidden一行,选择为 YES,还需增加 View controller-b

2017-05-09 17:22:58 1110

原创 iOS悬浮窗UIBezierPath圆形扩散转场动画

demo链接https://github.com/MinLee6/circleExtendedAnimation,self.startFrame:开始的起点位置self.presentView:随着圆扩展出现的视图view- (void)circleBigger { self.frame = CGRectMake(0, 0, [UIScr

2017-05-07 02:13:27 2934

转载 CABasicAnimation的基本使用方法(移动·旋转·放大·缩小)

博主:最近iOS开发中用到CoreAnimation的framework来做动画效果,虽然以前也用过,但一直没有系统学习过,今天看到一篇非常详细的博文(虽然是日语,但真的写的很好),在此翻译出来供大家学习。原帖地址:http://www.objectivec-iphone.com/animation/CoreAnimation/CABasicAnimation.html本文为博主翻

2017-05-06 23:54:28 504

转载 iOS播放GIF动画的几种方式

1.使用UIWebView播放#pragma clang diagnostic ignored "-Wnonnull" NSString *path = [[NSBundle mainBundle] pathForResource:@"" ofType:@"gif"]; NSData *gifData = [NSData dataWithContentsOfFile:path]

2017-05-05 18:01:37 513

转载 iOS之CAKeyframeAnimation关键帧动画详解

CABasicAnimation算是CAKeyFrameAnimation的 特殊情况,即不考虑中间变换过程,只考虑起始点与目标点就可以了。而CAKeyFrameAnimation则更复杂一些,允许我们在起点与终点间自定义 更多内容来达到我们的实际应用需求!比如,手机淘宝中,当你添加物品到购物车后会出现将物品抛到购物车的效果,这种效果实现起来也不难,无非是先绘制抛物 线在执行position以及s

2017-05-04 19:50:28 1552

音乐播放器

内置音乐播放器、歌词滚动、上一首歌曲、下一首歌曲、音量调节、摇一摇换歌曲等功能。

2015-09-08

音频、视频合成

ios中音频、视频合成,取消原视频音轨,和新的音轨合成一段视频。

2015-09-07

不会说话的汤姆猫

NSString *format=dict[@"imageFormat"]; NSInteger frames=[dict[@"frames"] integerValue]; NSMutableArray * imageList=[NSMutableArray array]; for (NSInteger i=0; i<frames; i++) { NSString *fileName=[NSString stringWithFormat:format,i]; UIImage* image=[UIImage imageNamed:fileName]; [imageList addObject:image]; } [_tomcatImageView setAnimationImages:imageList]; [_tomcatImageView setAnimationDuration:frames/10.0]; [_tomcatImageView setAnimationRepeatCount:1]; [_tomcatImageView startAnimating]; // NSArray *soundFiles=dict[@"soundFiles"]; if (soundFiles.count>0) { NSInteger seed=arc4random() %soundFiles.count; [self loadSoundWithFileName:soundFiles[seed]]; } }

2015-09-07

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除