kieuquangloc / iOSAnimation

This project will help you how to make iOS animation
1 stars 0 forks source link

Understanding Animation #1

Open phamsontm9x opened 6 years ago

phamsontm9x commented 6 years ago


Core Animation (Layer Animations)

 1. CAAnimation CAAnimation provides the basic support for the CAMediaTiming and CAAction protocols. You do not create instance of CAAnimation: to animate Core Animation layers or SceneKit objects, create instances of the concrete subclasses CABasicAnimation, CAKeyframeAnimation, CAAnimationGroup, or CATransition.




image

a. CAPropertyAnimation:

* An abstract subclass of CAAnimation for creating animations that manipulate the value of layer properties.

b. CABasicAnimation:

c. CAKeyframeAnimation:

image

2. Animation Groups 
a. CAAnimationGroup:

 An object that allows multiple animations to be grouped and run concurrently.  If you want to apply multiple animations to a layer object simultaneously, you can group them together using a CAAnimationGroup object. Using a group object simplifies the management of multiple animation objects by providing a single configuration point. Timing and duration values applied to the group override those same values in the individual animation objects. For example below the link: https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/CoreAnimation_guide/CreatingBasicAnimations/CreatingBasicAnimations.html

b. CATransaction

 CATransaction is the Core Animation mechanism for batching multiple layer-tree operations into atomic updates to the render tree. Every modification to a layer tree must be part of a transaction. Nested transactions are supported.  Advanced CATransition Tricks : https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/CoreAnimation_guide/AdvancedAnimationTricks/AdvancedAnimationTricks.html#//apple_ref/doc/uid/TP40004514-CH8-SW1

  3. Animation time

Layer Basics

image

  2. CALayerDeleagte

▪ You can implement the methods of this protocol to provide the layer’s content, handle the layout of sublayers, and provide custom animation actions to perform. The object that implements this protocol must be assigned to the delegate property of the layer object.


 4. CAAction

image

5. CALayoutManager

▪ Methods that allow an object to manage the layout of a layer and its sublayers.


6. CAConstraintLayoutManager
• An object that provides a constraint-based layout manager.



 7. CATransform 
Every layer has two transform matrices that you can to manipulate the layer.

View Animations

1. AnimationWithBlocks (UIViewAnimationWithBlocks)

phamsontm9x commented 6 years ago

I have some document about Animation. Follow the link below if you're interested. Have a good night ^^! https://drive.google.com/open?id=1QQKm4u524iyKgq8i-kJPtlKJalVNxvYy

kieuquangloc commented 6 years ago

Great man, thank you for sharing, have a sound sleep :))

On Tue, 24 Jul 2018 at 22:24, Thanh Sơn notifications@github.com wrote:

I have some document about Animation. Follow the link below if you're interested. Have a good night ^^! [(https://drive.google.com/open?id=1QQKm4u524iyKgq8i-kJPtlKJalVNxvYy)]

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/kieuquangloc147/iOSAnimation/issues/1#issuecomment-407447109, or mute the thread https://github.com/notifications/unsubscribe-auth/AHxWoKETsxzZCSVfeshXV-ug9fM8U9Myks5uJzw_gaJpZM4Vc8_C .