iOS燃烧动画、3D视图框架、天气动画、立体相册、微信朋友圈小视频等源码

iOS精选源码

iOS天气动画,包括太阳,云,雨,雷暴,雪动画。

image

较为美观的多级展开列表

image

3D立体相册,可以旋转的立方体

image

一个仪表盘Demo YGDashboardView

image

一个基于UIScrollView 实现的画轴异步分层动画展示界面

image

一个UIView扩展,可以显示燃烧视图的动画。

image

视图调试工具,视图的框架,并以2d / 3d样式显示

image

可修改系统相机和相册标题

image

GCD信号量与替代品Bolts(Facebook出品的第三方库)

image

仿微信朋友圈拍照/小视频

image


iOS优质博客

SDWebImage学习笔记之dispatch_sync

前言之前学习GCD的时候,在很多文章中看到过这段段代码:- (void)viewDidLoad {    ;    NSLog(@”1”);    dispatch_sync(di… 阅读原文

腾讯社招iOS面试记录

毕业好几年了,上周发送了简历给腾讯,参加了腾讯面试。具体部门这边就不说了。这次面试还是收获到了很多。一面电话面试:面试官主要是针对iOS相关的基础问题。先简单自我介绍一下自己对mrc和arc的理解谈谈对自动释放池的理解自动释放池在mrc和arc区别多层自动释放池嵌套的对象在哪一层释放对于block,理解,mrc和arc… 阅读原文

iOS 富文本如何添加图片

一、概念添加图片效果图富文本添加图片代码富文本总结直接拷贝代码就可以用二、添加图片效果图图1:三、富文本添加图片代码//  ViewController.m//  测试富文本  Created by joyshow on&… 阅读原文

React Native中的动画过渡

最近我在为下一个动画设计试着找新灵感,并在一个网站上看到了一些。我很好奇能否用React Native实现这些过渡。 我们可以看到上图包含了几个动画,工具栏(展示/隐藏),底边条(展示/隐藏),移动选定物品,隐藏所有其他物品,展示物品细节等等。动画的时间轴这个过渡的难点是让这些动画同步。我们不能真的取消挂载列… 阅读原文

iOS网络请求优化

最近发现很多网络请求都有可以优化的地方,虽然开发和测试都没有发现问题,但是可以让代码更加的优雅。想到了有四个方面可以优化,亲测有效。1. 页面返回的时候取消网络请求在一个界面进行多个请求的时候,而有可能用户马上点击了返回按钮,那么如果是使用了AFNetworking的情况,此时ViewController不会马上销毁,… 阅读原文



欢迎扫码关注微信公众号

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
import UIKit import QuartzCore import SceneKit class GameViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() // create a new scene let scene = SCNScene(named: "art.scnassets/ship.scn")! // create and add a camera to the scene let cameraNode = SCNNode() cameraNode.camera = SCNCamera() scene.rootNode.addChildNode(cameraNode) // place the camera cameraNode.position = SCNVector3(x: 0, y: 0, z: 15) // create and add a light to the scene let lightNode = SCNNode() lightNode.light = SCNLight() lightNode.light!.type = SCNLightTypeOmni lightNode.position = SCNVector3(x: 0, y: 10, z: 10) scene.rootNode.addChildNode(lightNode) // create and add an ambient light to the scene let ambientLightNode = SCNNode() ambientLightNode.light = SCNLight() ambientLightNode.light!.type = SCNLightTypeAmbient ambientLightNode.light!.color = UIColor.darkGrayColor() scene.rootNode.addChildNode(ambientLightNode) // retrieve the ship node let ship = scene.rootNode.childNodeWithName("ship", recursively: true)! // animate the 3d object ship.runAction(SCNAction.repeatActionForever(SCNAction.rotateByX(0, y: 2, z: 0, duration: 1))) // retrieve the SCNView let scnView = self.view as! SCNView // set the scene to the view scnView.scene = scene // allows the user to manipulate the camera scnView.allowsCameraControl = true // show statistics such as fps and timing information scnView.showsStatistics = true // configure the view scnView.backgroundColor = UIColor.blackColor() // add a tap gesture recognizer let tapGesture = UITapGestureRecognizer(target: self, action: "handleTap:") scnView.addGestureRecognizer(tapGesture) } func handleTap(gestureRecognize: UIGestureRecognizer) { // retrieve the SCNView let scnView = self.view as! SCNView // check what nodes are tapped let p = gestureRecognize.locationInView(scnView) let hitResults = scnView.hitTest(p, options: nil) // check that we clicked on at least one object if hitResults.count > 0 { // retrieved the first clicked object let result: AnyObject! = hitResults[0] // get its material let material = result.node!.geometry!.firstMaterial! // highlight it SCNTransaction.begin() SCNTransaction.setAnimationDuration(0.5) // on completion - unhighlight SCNTransaction.setCompletionBlock { SCNTransaction.begin() SCNTransaction.setAnimationDuration(0.5) material.emission.contents = UIColor.blackColor() SCNTransaction.commit() } material.emission.contents = UIColor.redColor() SCNTransaction.commit() } } override func shouldAutorotate() -> Bool { return true } override func prefersStatusBarHidden() -> Bool { return true } override func supportedInterfaceOrientations() -> UIInterfaceOrientationMask { if UIDevice.currentDevice().userInterfaceIdiom == .Phone { return .AllButUpsideDown } else { return .All } } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Release any cached data, images, etc that aren't in use. } }
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值