版本記錄
| 版本號 | 時間 |
|---|---|
| V1.0 | 2017.09.24 |
前言
app中好的炫的動畫可以讓用戶耳目一新,為產(chǎn)品增色不少,關(guān)于動畫的實現(xiàn)我們可以用基本動畫、關(guān)鍵幀動畫、序列幀動畫以及基于CoreGraphic的動畫等等,接下來這幾篇我就介紹下我可以想到的幾種動畫繪制方法。具體Demo示例已開源到Github —— 刀客傳奇,感興趣的可以看我寫的另外幾篇。
1. 實現(xiàn)動畫方式深度解析(一) —— 播放GIF動畫(一)
2. 實現(xiàn)動畫方式深度解析(二) —— 播放GIF動畫之框架FLAnimatedImage的使用(二)
3. 實現(xiàn)動畫方式深度解析(三) —— 播放序列幀動畫(一)
4. 實現(xiàn)動畫方式深度解析(四) —— QuartzCore框架(一)
5. 實現(xiàn)動畫方式深度解析(五) —— QuartzCore框架之CoreAnimation(二)
6. 實現(xiàn)動畫方式深度解析(六) —— Core Animation Basics(三)
7. 實現(xiàn)動畫方式深度解析(七) —— Core Animation之Setting Up Layer Objects(四)
8. 實現(xiàn)動畫方式深度解析(八) —— Core Animation之動畫層內(nèi)容 (五)
9. 實現(xiàn)動畫方式深度解析(九) —— Core Animation之構(gòu)建圖層層級 (六)
10. 實現(xiàn)動畫方式深度解析(十) —— Core Animation之高級動畫技巧 (七)
11. 實現(xiàn)動畫方式深度解析(十一) —— Core Animation之更改圖層的默認(rèn)行為(八)
12. 實現(xiàn)動畫方式深度解析(十二) —— Core Animation之提高動畫的性能(九)
13. 實現(xiàn)動畫方式深度解析(十三) —— Core Animation之圖層樣式屬性動畫(十)
14. 實現(xiàn)動畫方式深度解析(十四) —— Core Animation之 KVC 擴(kuò)展(十一)
Animatable Properties - 可動畫屬性
CALayer和CIFilter中的許多屬性都可以動畫化。 本附錄列出了這些屬性,以及默認(rèn)使用的動畫。
CALayer Animatable Properties - CALayer可動畫屬性
下表列出了您可能考慮動畫化的CALayer類的屬性。 對于每個屬性,該表還列出了創(chuàng)建用于執(zhí)行隱式動畫的默認(rèn)動畫對象的類型。
| Property | Default animation |
|---|---|
| anchorPoint | Uses the default implied CABasicAnimation object, described in Table B-2. |
| backgroundColor | Uses the default implied CABasicAnimation object, described in Table B-2. |
| backgroundFilters | Uses the default implied CATransition object, described in Table B-3. Sub-properties of the filters are animated using the default |
| borderColor | Uses the default implied CABasicAnimation object, described in Table B-2. |
| borderWidth | Uses the default implied CABasicAnimation object, described in Table B-2. |
| bounds | Uses the default implied CABasicAnimation object, described in Table B-2. |
| compositingFilter | Uses the default implied CATransition object, described in Table B-3. Sub-properties of the filters are animated using the default implied CABasicAnimation object, described in Table B-2. |
| contents | Uses the default implied CABasicAnimation object, described in Table B-2. |
| contentsRect | Uses the default implied CABasicAnimation object, described in Table B-2. |
| cornerRadius | Uses the default implied CABasicAnimation object, described in Table B-2. |
| doubleSided | There is no default implied animation. |
| filters | Uses the default implied CABasicAnimation object, described in Table B-2. Sub-properties of the filters are animated using the default implied CABasicAnimation object, described in Table B-2. |
| frame | This property is not animatable. You can achieve the same results by animating the bounds and position properties. |
| hidden | Uses the default implied CABasicAnimation object, described in Table B-2. |
| mask | Uses the default implied CABasicAnimation object, described in Table B-2. |
| masksToBounds | Uses the default implied CABasicAnimation object, described in Table B-2. |
| opacity | Uses the default implied CABasicAnimation object, described in Table B-2. |
| position | Uses the default implied CABasicAnimation object, described in Table B-2. |
| shadowColor | Uses the default implied CABasicAnimation object, described in Table B-2. |
| shadowOffset | Uses the default implied CABasicAnimation object, described in Table B-2. |
| shadowOpacity | Uses the default implied CABasicAnimation object, described in Table B-2. |
| shadowPath | Uses the default implied CABasicAnimation object, described in Table B-2. |
| shadowRadius | Uses the default implied CABasicAnimation object, described in Table B-2. |
| sublayers | Uses the default implied CABasicAnimation object, described in Table B-2. |
| sublayerTransform | Uses the default implied CABasicAnimation object, described in Table B-2. |
| transform | Uses the default implied CABasicAnimation object, described in Table B-2. |
| zPosition | Uses the default implied CABasicAnimation object, described in Table B-2. |
下表列出了默認(rèn)基于屬性的動畫的動畫屬性。

下表列出了默認(rèn)基于過渡的動畫的動畫對象配置。

CIFilter Animatable Properties - 可動畫屬性
Core Animation為Core Image的CIFilter類添加了以下可動畫屬性。 這些屬性僅在OS X上可用。
后記
未完,待續(xù)~~~
