bryanoltman / caanimation-easingequations Goto Github PK
View Code? Open in Web Editor NEWA category on CAAnimation that provides a number of easing equations to add some zazz to your app (with examples!)
License: MIT License
A category on CAAnimation that provides a number of easing equations to add some zazz to your app (with examples!)
License: MIT License
Looking at the docs, it seems the only values supported here are CGFloat
s. How could I go about adding support for more generic NSValue
s like with CATransform3D
?
i.e. [NSValue valueWithCATransform3D:transform]
Looking at the Apple Docs for CAKeyframeAnimation
, generic NSValue
s seem supported.
For reference, here's my original code using CABasicAnimation
:
CABasicAnimation *animation = [CABasicAnimation animationWithKeyPath:@"transform"];
CATransform3D transform = CATransform3DIdentity;
transform.m34 = 1.0/400.0;
transform = CATransform3DRotate(transform, M_PI, 0, 1, 0);
[animation setToValue:[NSValue valueWithCATransform3D:transform]];
[animation setDuration:0.5];
[animation setTimingFunction:[CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseOut]];
animation.delegate = self;
[self.layer addAnimation:animation forKey:@"3dtransform"];
Thanks for helping out!
Please indicate the license for this code.
Hi!
Your lib save my time, thanks!
I tried to create a Pod with your lib, but I could not because needs a homepage and suggests a lib version. :(
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.