一,code// 创建UIImageView UIImageView* topView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"IMG_1483"]]; topView.frame = CGRectMake(0, -HGTopViewH, self.tableView.frame.size.width, HGTopViewH); // 设置模式,自动伸缩,全拼显示 topView.contentMode = UIViewContentModeScaleAspectFill; // 支持旋转 topView.autoresizingMask = UIViewAutoresizingFlexibleWidth; // 将UIImageV...
1.实现原理:将所有按钮放在viewcontroller的_buttonArray集合中,同时赋值给按钮中增加长按手势的响应当手势坐标进入其他按钮的frame时,调整集合中按钮位置;当长按手势开始,放大按钮; 结束时还原按钮2.附源码及注释[按钮调控没有动画]@interface UIDragButton : UIButton {
CGPoint _prePoint; // 移动过程中的上一个点
BOOL _isPress; // 是否按下:实现过程未用到
CGPoi...
原创链接:http://blog.csdn.net/zhao_3546/article/details/12893167,转载请注明,谢谢。距离上篇博客《Android 4.3实现类似iOS在音乐播放过程中如果有来电则音乐声音渐小铃声渐大的效果》 已经快有4个月了,期间有空写一点,直到今天才完整地写完。目前Android的实现是:有来电时,音乐声音直接停止,铃声直接直接使用设置的铃声音量进行铃声播放。Android 4.3实现类似iOS在音乐播放过程中如果有来电则音乐声音渐小铃声渐大的效...
开发中用到UIPickerView显示和隐藏的动画.随手记一下第一步:写一个动画方法- (void)ViewAnimation:(UIView*)view willHidden:(BOOL)hidden {[UIView animateWithDuration:0.3 animations:^{if (hidden) {view.frame = CGRectMake(0, [UIScreen mainScreen].bounds.size.height, [UIScreen mainScreen].bounds.size.width, view.bounds.size.height);} else {[view setHidden:hidden];view.frame = CGRectMake(0, [UIScreen mainScr...
使用GPUImageSketchFilter对象实现图像素描效果NSString *const kGPUImageSketchFragmentShaderString = SHADER_STRING
(precision mediump float;varying vec2 textureCoordinate;varying vec2 leftTextureCoordinate;varying vec2 rightTextureCoordinate;varying vec2 topTextureCoordinate;varying vec2 topLeftTextureCoordinate;varying vec2 topRightTextureCoordinate;varying vec2 bottomTextureCoordinate;varying vec2 ...
UIVisualEffectView实现两种模糊效果:UIBlurEffect 和 UIVibrancyEffect两者都是继承自UIView,前者放在任意的View里边都能对下册的视图渲染出模糊效果,后者是在前者的基础上对毛玻璃效果上层的视图做出高亮突出处理代码如下: @IBOutlet weak var imageView: UIImageView!override func viewDidLoad() {super.viewDidLoad()var blurEffect = UIBlurEffect(style: UIBlurEffectStyle.Light)var blurEffectView = UIVisualEffectV...
原文链接:iOS文字滚动效果 之横向滚动 简书主页:http://www.jianshu.com/users/37f2920f6848Github主页:https://github.com/MajorLMJiOS开发者公会-技术1群 QQ群号:87440292iOS开发者公会-技术2群 QQ群号:232702419iOS开发者公会-议事区 QQ群号:413102158原文:http://www.cnblogs.com/lmj123/p/5829939.html
iPhone是智能手机的标杆,那么iOS系统也成为了移动系统的标杆,9月17日凌晨,苹果发布了ios9,让很多国人的果粉兴奋不已,下面小编也为大家分享PS制作ios9系统的界面毛玻璃效果教程,一起来看看吧!方法/步骤1、首先,新建颜色模式RGB文件,尺寸按照iOS常用手机界面标准:1334x750像素,分辨率设置为722、拖入临摹图,按照图片里的分区,用移动工具从标尺处拉出一条参考线3、Ctrl+H暂时隐藏参考线,直接拖入素材图。在Photoshop CS...
在手机里面经常可以看到模糊效果,比如说控制中心。那么这种效果怎么去实现的呢,一般有一下几种办法。1.CoreImage2.vImage(UIImageView+Effective)3.GPUImage4.UIVisualEfftiveView下面来说说这几种方法的使用方法:一、CoreImage 1 - (void)test1 {2//原始图片 3 UIImage *originImage = [UIImage imageNamed:@"bg1.jpg"];4//创建上下文 5 CIContext *context = [CIContext contextWithOptions:nil];6//将原始图片转换成...
ViewController.h 1#import <UIKit/UIKit.h>2 3@interface ViewController : UIViewController{4 NSTimer *timer;5 UIScrollView *scrollViewText;6}7 8 @property (nonatomic ,strong) NSArray *arrData;91011@endViewController.m 1// 2// ViewController.m3// 跑马灯文字广告4// 5// Created by Time.X on 16/2/15.6// Copyright ? 2016年 Time.X. All rights reserved.7//8 9#import"ViewContr...
反色是与原色叠加可以变为白色的颜色,即用白色(RGB:1.0,1.0,1.0)减去原色的颜色。比如说红色(RGB:1.0,0,0)的反色是青色(0,1.0,1.0)。在OPENGL ES中为1. 通过导入GPUImage库的GPUImageColorInvertFilter来实现iOS的图像反色处理 1(2 varying highp vec2 textureCoordinate;3 4 uniform sampler2D inputImageTexture;5 6void main()7 {8 lowp vec4 textureColor = texture2D(inputImageTexture, textureCoordi...
iOS开发之抽屉效果实现 说道抽屉效果在iOS中比较有名的第三方类库就是PPRevealSideViewController。一说到第三方类库就自然而然的想到我们的CocoaPods,今天的博客中用CocoaPods引入PPRevealSideViewController,然后在我们的工程中以代码结合storyboard来做出抽屉效果。一.在工程中用CocoaPods引入第三方插件PPRevealSideViewController. (1).在终端中搜索PPRevealSideViewController的版本 (2).在Podfile中添加相应的版本库...
//
// AMBlurView.h
// blur
//
// Created by Dubai Pinto Castillo on 7/3/15.
// Copyright (c) 2013 Dubai All rights reserved.
//#import <UIKit/UIKit.h>@interface JCRBlurView :
UIView
// Use the following property to set the tintColor. Set it to nil to reset.
@property (nonatomic,
strong) UIColor *blurTintColor;
@endJCRBlurView.m为:
//
// AMBlurView.m
// blur
//
// Created by Dubai Pinto Cast...
UIImageView * image=[[UIImageView alloc]init]; image.frame=CGRectMake(0, 0, 320, 568); image.image=[UIImage imageNamed:@"Guide_img_1"]; [self.view addSubview:image]; UIBlurEffect * blur = [UIBlurEffect effectWithStyle:UIBlurEffectStyleExtraLight]; UIVisualEffectView * effe = [[UIVisualEffectView alloc]initWithEffect:blur]; effe.frame = CGRectMake(0, 0, self.view.frame.size.wi...
效果体验:http://keleyi.com/keleyi/phtml/html5/28.htm以下是代码:<!doctype html><html><head><meta charset="utf-8"><title>模拟苹果ios系统页面过渡效果插件-柯乐义</title><base target="_blank"/><link rel="stylesheet" href="http://keleyi.com/keleyi/phtml/html5/28/css/kontext.css"><link rel="stylesheet" href="http://keleyi.com/keleyi/phtml/html5/28/css/demo.css"></head><body><article class="keleyi"><div...