在线观看不卡亚洲电影_亚洲妓女99综合网_91青青青亚洲娱乐在线观看_日韩无码高清综合久久

鍍金池/ 教程/ Android/ alpha、scale、translate、rotate、set 的 xml 屬性及用法
聯(lián)合動(dòng)畫的 XML 實(shí)現(xiàn)與使用示例
Interpolator 插值器
高級(jí)進(jìn)階(二)
ObjectAnimator 基本使用
ValueAnimator 基本使用
alpha、scale、translate、rotate、set 的 xml 屬性及用法
PropertyValuesHolder 與 Keyframe
layoutAnimation 與 gridLayoutAnimation
自定義控件三部曲之動(dòng)畫篇(十三)——實(shí)現(xiàn)ListView Item進(jìn)入動(dòng)畫
自定義控件三部曲之動(dòng)畫篇(十二)——animateLayoutChanges與LayoutTransition
高級(jí)進(jìn)階(一)
代碼生成 alpha、scale、translate、rotate、set 及插值器動(dòng)畫
聯(lián)合動(dòng)畫的代碼實(shí)現(xiàn)

alpha、scale、translate、rotate、set 的 xml 屬性及用法

一、概述

Android 的 animation 由四種類型組成:alpha、scale、translate、rotate,對(duì)應(yīng) android 官方文檔地址:《Animation Resources》

1、XML 配置文件中

alpha 漸變透明度動(dòng)畫效果
scale 漸變尺寸伸縮動(dòng)畫效果
translate 畫面轉(zhuǎn)換位置移動(dòng)動(dòng)畫效果
rotate 畫面轉(zhuǎn)移旋轉(zhuǎn)動(dòng)畫效果

下面我們逐個(gè)講講每個(gè)標(biāo)簽的屬性及用法。

2、動(dòng)作文件存放位置

動(dòng)作定義文件應(yīng)該存放在 res/anim 文件夾下,訪問(wèn)時(shí)采用 R.anim.XXX.xml 的方式,位置如圖:

http://wiki.jikexueyuan.com/project/android-animation/images/1.png" alt="" />

二、scale 標(biāo)簽——調(diào)節(jié)尺寸

1、自有屬性

scale 標(biāo)簽是縮放動(dòng)畫,可以實(shí)現(xiàn)動(dòng)態(tài)調(diào)控件尺寸的效果,有下面幾個(gè)屬性:

  • android:fromXScale 起始的 X 方向上相對(duì)自身的縮放比例,浮點(diǎn)值,比如 1.0 代表自身無(wú)變化,0.5 代表起始時(shí)縮小一倍,2.0 代表放大一倍;
  • android:toXScale 結(jié)尾的 X 方向上相對(duì)自身的縮放比例,浮點(diǎn)值;
  • android:fromYScale 起始的 Y 方向上相對(duì)自身的縮放比例,浮點(diǎn)值,
  • android:toYScale 結(jié)尾的 Y 方向上相對(duì)自身的縮放比例,浮點(diǎn)值;
  • android:pivotX 縮放起點(diǎn) X 軸坐標(biāo),可以是數(shù)值、百分?jǐn)?shù)、百分?jǐn)?shù) p 三種樣式,比如 50、50%、50%p,當(dāng)為數(shù)值時(shí),表示在當(dāng)前 View 的左上角,即原點(diǎn)處加上 50px,做為起始縮放點(diǎn);如果是 50%,表示在當(dāng)前控件的左上角加上自己寬度的 50%做為起始點(diǎn);如果是 50%p,那么就是表示在當(dāng)前的左上角加上父控件寬度的 50%做為起始點(diǎn) x 軸坐標(biāo)。(具體意義,后面會(huì)舉例演示)
  • android:pivotY 縮放起點(diǎn) Y 軸坐標(biāo),取值及意義跟 android:pivotX 一樣。

下面看一個(gè)實(shí)例,當(dāng) scale 里的屬性這樣設(shè)置時(shí),效果會(huì)怎樣呢:

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50"  
    android:pivotY="50"  
    android:duration="700" />  

(1)、pivotX 取值數(shù)值時(shí)(50)

這個(gè)控件,寬度和高度都是從 0 放大到 1.4 倍,起始點(diǎn)坐標(biāo)在控件左上角(坐標(biāo)原點(diǎn)),向 x 軸正方向和 y 軸正方向都加上 50 像素; 根據(jù) pivotX,pivotY 的意義,控件的左上角即為控件的坐標(biāo)原點(diǎn),這里的起始點(diǎn)是在控件的原點(diǎn)的基礎(chǔ)上向 X 軸和 Y 軸各加上 50px,做為起始點(diǎn),如下圖中圖二所示

圖一 http://wiki.jikexueyuan.com/project/android-animation/images/1.gif" alt="" />

圖二 http://wiki.jikexueyuan.com/project/android-animation/images/2.png" alt="" />

(2)、pivotX 取值百分?jǐn)?shù)時(shí)(50%) 下面再看看當(dāng) pivotX、pivotY 取百分?jǐn)?shù)的時(shí)候,起始點(diǎn)又在哪里?

上面我們講了,pivotX 的值,當(dāng)取 50%時(shí),表示在原點(diǎn)坐標(biāo)的基礎(chǔ)上加上的自己寬度的 50%,看看效果:

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%"  
    android:pivotY="50%"  
    android:duration="700" />  

縮放位置大小仍然從 0-1.4,只改變 pivotX 和 pivotY;起始點(diǎn)位置如下圖中圖二所示:

圖一 http://wiki.jikexueyuan.com/project/android-animation/images/2.gif" alt="" />

圖二 http://wiki.jikexueyuan.com/project/android-animation/images/3.png" alt="" />

(3)、pivotX 取值 50%p 時(shí)

前面說(shuō)過(guò),當(dāng)取值在百分?jǐn)?shù)后面加上一個(gè)字母 p,就表示,取值的基數(shù)是父控件,即在原點(diǎn)的基礎(chǔ)上增加的值是父標(biāo)簽的百分值。

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%p"  
    android:pivotY="50%p"  
    android:duration="700" />  

效果圖,及起始點(diǎn)坐標(biāo)圖如下所示:

http://wiki.jikexueyuan.com/project/android-animation/images/3.gif" alt="" />

http://wiki.jikexueyuan.com/project/android-animation/images/4.png" alt="" />

2、從 Animation 類繼承的屬性

Animation 類是所有動(dòng)畫(scale、alpha、translate、rotate)的基類,這里以 scale 標(biāo)簽為例,講解一下,Animation 類所具有的屬性及意義。關(guān)于 Animation 類的官方文檔位置為:《Animation》

  • android:duration 動(dòng)畫持續(xù)時(shí)間,以毫秒為單位
  • android:fillAfter 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),將保持動(dòng)畫最后時(shí)的狀態(tài)
  • android:fillBefore 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),還原到開(kāi)始動(dòng)畫前的狀態(tài)
  • android:fillEnabled 與 android:fillBefore 效果相同,都是在動(dòng)畫結(jié)束時(shí),將控件還原到初始化狀態(tài)
  • android:repeatCount 重復(fù)次數(shù)
  • android:repeatMode 重復(fù)類型,有 reverse 和 restart 兩個(gè)值,reverse 表示倒序回放,restart 表示重新放一遍,必須與 repeatCount 一起使用才能看到效果。因?yàn)檫@里的意義是重復(fù)的類型,即回放時(shí)的動(dòng)作。
  • android:interpolator 設(shè)定插值器,其實(shí)就是指定的動(dòng)作效果,比如彈跳效果等,不在這小節(jié)中講解,后面會(huì)單獨(dú)列出一單講解。

對(duì)于 android:duration,就不再講解了,就是動(dòng)畫的持續(xù)時(shí)長(zhǎng),以毫秒為單位,下面看看 android:fillAfter 和 android:fillBefore

(1)android:fillAfter:保持動(dòng)畫結(jié)束的狀態(tài)

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%"  
    android:pivotY="50%"  
    android:duration="700"   
    android:fillAfter="true"  
    />  

http://wiki.jikexueyuan.com/project/android-animation/images/4.gif" alt="" />

(2)android:fillBefore 還原初始化狀態(tài)

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%"  
    android:pivotY="50%"  
    android:duration="700"   
    android:fillBefore="true"  
    />  

android:fillBefore="true" http://wiki.jikexueyuan.com/project/android-animation/images/5.gif" alt="" />

android:fillEnable="true" http://wiki.jikexueyuan.com/project/android-animation/images/6.gif" alt="" />

上面順便列出了,當(dāng)僅設(shè)定 fillEanble 為 true 時(shí)的效果,這兩個(gè)的標(biāo)簽的效果完全相同。

(3)、android:repeatMode="restart /reverse" 設(shè)定回放類型

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%"  
    android:pivotY="50%"  
    android:duration="700"   
    android:fillBefore="true"  
    android:repeatCount="1"  
    android:repeatMode="restart"  
/>  

androidRepeatMode 設(shè)為 restart http://wiki.jikexueyuan.com/project/android-animation/images/7.gif" alt="" />

androidRepeatMode 設(shè)為 reverse http://wiki.jikexueyuan.com/project/android-animation/images/8.gif" alt="" />

三、alpha 標(biāo)簽——調(diào)節(jié)透明度

1、自身屬性

  • android:fromAlpha 動(dòng)畫開(kāi)始的透明度,從 0.0 --1.0 ,0.0 表示全透明,1.0 表示完全不透明
  • android:toAlpha 動(dòng)畫結(jié)束時(shí)的透明度,也是從 0.0 --1.0 ,0.0 表示全透明,1.0 表示完全不透明 使用示例:
<?xml version="1.0" encoding="utf-8"?>  
<alpha xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromAlpha="1.0"  
    android:toAlpha="0.1"  
    android:duration="3000"  
    android:fillBefore="true">  
</alpha>  

http://wiki.jikexueyuan.com/project/android-animation/images/9.gif" alt="" />

2、從 Animation 類繼承的屬性

  • android:duration 動(dòng)畫持續(xù)時(shí)間,以毫秒為單位
  • android:fillAfter 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),將保持動(dòng)畫最后時(shí)的狀態(tài)
  • android:fillBefore 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),還原到開(kāi)始動(dòng)畫前的狀態(tài)
  • android:fillEnabled 與 android:fillBefore 效果相同,都是在動(dòng)畫結(jié)束時(shí),將控件還原到初始化狀態(tài)
  • android:repeatCount 重復(fù)次數(shù)
  • android:repeatMode 重復(fù)類型,有 reverse 和 restart 兩個(gè)值,reverse 表示倒序回放,restart 表示重新放一遍,必須與 repeatCount 一起使用才能看到效果。因?yàn)檫@里的意義是重復(fù)的類型,即回放時(shí)的動(dòng)作。
  • android:interpolator 設(shè)定插值器,其實(shí)就是指定的動(dòng)作效果,比如彈跳效果等,不在這小節(jié)中講解,后面會(huì)單獨(dú)列出一單講解。

與 scale 標(biāo)簽意義一樣,就不再綴述。

四、rotate 標(biāo)簽——旋轉(zhuǎn)

1、自身屬性

  • android:fromDegrees 開(kāi)始旋轉(zhuǎn)的角度位置,正值代表順時(shí)針?lè)较蚨葦?shù),負(fù)值代碼逆時(shí)針?lè)较蚨葦?shù)
  • android:toDegrees 結(jié)束時(shí)旋轉(zhuǎn)到的角度位置,正值代表順時(shí)針?lè)较蚨葦?shù),負(fù)值代碼逆時(shí)針?lè)较蚨葦?shù)
  • android:pivotX 縮放起點(diǎn) X 軸坐標(biāo),可以是數(shù)值、百分?jǐn)?shù)、百分?jǐn)?shù) p 三種樣式,比如 50、50%、50%p,具體意義已在 scale 標(biāo)簽中講述,這里就不再重講
  • android:pivotY 縮放起點(diǎn) Y 軸坐標(biāo),可以是數(shù)值、百分?jǐn)?shù)、百分?jǐn)?shù) p 三種樣式,比如 50、50%、50%p
<?xml version="1.0" encoding="utf-8"?>  
<rotate xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromDegrees="0"  
    android:toDegrees="-650"  
    android:pivotX="50%"  
    android:pivotY="50%"  
    android:duration="3000"  
    android:fillAfter="true">  

</rotate>  

圍繞自身從 0 度逆時(shí)針旋轉(zhuǎn) 650 度 android:fromDegrees="0" android:toDegrees="-650" http://wiki.jikexueyuan.com/project/android-animation/images/10.gif" alt="" />

圍繞自身從 0 度順時(shí)針旋轉(zhuǎn) 650 度 android:fromDegrees="0" android:toDegrees="650" http://wiki.jikexueyuan.com/project/android-animation/images/11.gif" alt="" />

2、從 Animation 類繼承的屬性

  • android:duration 動(dòng)畫持續(xù)時(shí)間,以毫秒為單位
  • android:fillAfter 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),將保持動(dòng)畫最后時(shí)的狀態(tài)
  • android:fillBefore 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),還原到開(kāi)始動(dòng)畫前的狀態(tài)
  • android:fillEnabled 與 android:fillBefore 效果相同,都是在動(dòng)畫結(jié)束時(shí),將控件還原到初始化狀態(tài)
  • android:repeatCount 重復(fù)次數(shù)
  • android:repeatMode 重復(fù)類型,有 reverse 和 restart 兩個(gè)值,reverse 表示倒序回放,restart 表示重新放一遍,必須與 repeatCount 一起使用才能看到效果。因?yàn)檫@里的意義是重復(fù)的類型,即回放時(shí)的動(dòng)作。
  • android:interpolator 設(shè)定插值器,其實(shí)就是指定的動(dòng)作效果,比如彈跳效果等,不在這小節(jié)中講解,后面會(huì)單獨(dú)列出一單講解。

與 scale 標(biāo)簽意義一樣,就不再綴述。

五、translate 標(biāo)簽 —— 平移

1、自身屬性

  • android:fromXDelta 起始點(diǎn) X 軸坐標(biāo),可以是數(shù)值、百分?jǐn)?shù)、百分?jǐn)?shù) p 三種樣式,比如 50、50%、50%p,具體意義已在 scale 標(biāo)簽中講述,這里就不再重講
  • android:fromYDelta 起始點(diǎn) Y 軸從標(biāo),可以是數(shù)值、百分?jǐn)?shù)、百分?jǐn)?shù) p 三種樣式;
  • android:toXDelta 結(jié)束點(diǎn) X 軸坐標(biāo)
  • android:toYDelta 結(jié)束點(diǎn) Y 軸坐標(biāo)
<?xml version="1.0" encoding="utf-8"?>  
<translate xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXDelta="0"   
    android:toXDelta="-80"  
    android:fromYDelta="0"  
    android:toYDelta="-80"  
    android:duration="2000"  
    android:fillBefore="true">  
</translate>  

http://wiki.jikexueyuan.com/project/android-animation/images/12.gif" alt="" />

2、從 Animation 類繼承的屬性

  • android:duration 動(dòng)畫持續(xù)時(shí)間,以毫秒為單位
  • android:fillAfter 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),將保持動(dòng)畫最后時(shí)的狀態(tài)
  • android:fillBefore 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),還原到開(kāi)始動(dòng)畫前的狀態(tài)
  • android:fillEnabled 與 android:fillBefore 效果相同,都是在動(dòng)畫結(jié)束時(shí),將控件還原到初始化狀態(tài)
  • android:repeatCount 重復(fù)次數(shù)
  • android:repeatMode 重復(fù)類型,有 reverse 和 restart 兩個(gè)值,reverse 表示倒序回放,restart 表示重新放一遍,必須與 repeatCount 一起使用才能看到效果。因?yàn)檫@里的意義是重復(fù)的類型,即回放時(shí)的動(dòng)作。
  • android:interpolator 設(shè)定插值器,其實(shí)就是指定的動(dòng)作效果,比如彈跳效果等,不在這小節(jié)中講解,后面會(huì)單獨(dú)列出一單講解。

與 scale 標(biāo)簽意義一樣,就不再綴述。

六、set 標(biāo)簽——定義動(dòng)作合集

前面我們講解了各個(gè)標(biāo)簽動(dòng)畫的意義及用法,但他們都是獨(dú)立對(duì)控件起作用,假設(shè)我現(xiàn)在想上面的 textView 控件做一個(gè)動(dòng)畫——從小到大,旋轉(zhuǎn)出場(chǎng),而且透明度也要從 0 變成 1,即下面的這個(gè)效果,該怎么辦?

http://wiki.jikexueyuan.com/project/android-animation/images/13.gif" alt="" />

這就需要對(duì)指定的控件定義動(dòng)作合集,Set 標(biāo)簽就可以將幾個(gè)不同的動(dòng)作定義成一個(gè)組;

屬性: set 標(biāo)簽自已是沒(méi)有屬性的,他的屬性都是從 Animation 繼承而來(lái),但當(dāng)它們用于 Set 標(biāo)簽時(shí),就會(huì)對(duì) Set 標(biāo)簽下的所有子控件都產(chǎn)生作用。

屬性有:(從 Animation 類繼承的屬性)

  • android:duration 動(dòng)畫持續(xù)時(shí)間,以毫秒為單位
  • android:fillAfter 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),將保持動(dòng)畫最后時(shí)的狀態(tài)
  • android:fillBefore 如果設(shè)置為 true,控件動(dòng)畫結(jié)束時(shí),還原到開(kāi)始動(dòng)畫前的狀態(tài)
  • android:fillEnabled 與 android:fillBefore 效果相同,都是在動(dòng)畫結(jié)束時(shí),將控件還原到初始化狀態(tài)
  • android:repeatCount 重復(fù)次數(shù)
  • android:repeatMode 重復(fù)類型,有 reverse 和 restart 兩個(gè)值,reverse 表示倒序回放,restart 表示重新放一遍,必須與 repeatCount 一起使用才能看到效果。因?yàn)檫@里的意義是重復(fù)的類型,即回放時(shí)的動(dòng)作。
  • android:interpolator 設(shè)定插值器,其實(shí)就是指定的動(dòng)作效果,比如彈跳效果等,不在這小節(jié)中講解,后面會(huì)單獨(dú)列出一單講解。

與 scale 標(biāo)簽意義一樣,就不再綴述。

上面這個(gè)效果,所對(duì)應(yīng)的 XML 代碼為:

<?xml version="1.0" encoding="utf-8"?>  
<set xmlns:android="http://schemas.android.com/apk/res/android"  
    android:duration="3000"  
    android:fillAfter="true">  

  <alpha   
    android:fromAlpha="0.0"  
    android:toAlpha="1.0"/>  

  <scale  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%"  
    android:pivotY="50%"/>  

  <rotate  
    android:fromDegrees="0"  
    android:toDegrees="720"  
    android:pivotX="50%"  
    android:pivotY="50%"/>  

</set>  

七、實(shí)例——如何將動(dòng)畫 XML 文件應(yīng)用于控件中

上面我僅僅是列出了每個(gè)標(biāo)簽及其屬性的意義及應(yīng)用之后的效果演示,但上面是如何將定義動(dòng)畫的 xml 應(yīng)用到 textView 控件中的卻遲遲沒(méi)說(shuō),這一小節(jié),就以 scale 動(dòng)畫為例,講述如何將定義好的 scle 動(dòng)作添加到指定控件中。

先看最終效果圖:

http://wiki.jikexueyuan.com/project/android-animation/images/14.gif" alt="" />

1、新建工程、新建 scale 動(dòng)畫文件(scaleanim.xml)

新建一個(gè)工程,并且在 res 文件夾下,新建一個(gè) anim 文件夾,然后再新建一個(gè) scaleanim.xml 文件,結(jié)構(gòu)如圖所示:

http://wiki.jikexueyuan.com/project/android-animation/images/5.png" alt="" />

scaleanim.xml 的代碼為:(從 TextView 中心點(diǎn),從 0 放大到 1.4 倍,反復(fù)一次,最后還原到初始化狀態(tài))

<?xml version="1.0" encoding="utf-8"?>  
<scale xmlns:android="http://schemas.android.com/apk/res/android"  
    android:fromXScale="0.0"  
    android:toXScale="1.4"  
    android:fromYScale="0.0"  
    android:toYScale="1.4"  
    android:pivotX="50%"  
    android:pivotY="50%"  
    android:duration="700"   
    android:fillBefore="true"  
    android:repeatCount="1"  
    android:repeatMode="restart"  
/> 

2、XML 布局文件

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"  
    xmlns:tools="http://schemas.android.com/tools"  
    android:layout_width="match_parent"  
    android:layout_height="match_parent"  
    android:orientation="vertical"  
    tools:context="com.harvic.animation_demo.MainActivity" >  

    <Button android:id="@+id/btn_animation"  
        android:layout_width="match_parent"  
        android:layout_height="wrap_content"  
        android:layout_margin="10dip"  
        android:text="scale animation"/>  
    <TextView  
        android:id="@+id/tv"  
        android:layout_width="100dip"  
        android:layout_height="200dip"  
        android:background="#ff00ff"   
        android:text="@string/hello_world"  
        android:layout_gravity="center_horizontal"/>  

</LinearLayout>  

3、JAVA 代碼

public class MainActivity extends Activity {  

    Button scaleBtn ;  
    Animation scaleAnimation;  

    TextView tv;  
    @Override  
    protected void onCreate(Bundle savedInstanceState) {  
        super.onCreate(savedInstanceState);  
        setContentView(R.layout.activity_main);  

        scaleAnimation = AnimationUtils.loadAnimation(this, R.anim.scaleanim);  
        scaleBtn = (Button)findViewById(R.id.btn_animation);  
        tv =(TextView)findViewById(R.id.tv);  

        scaleBtn.setOnClickListener(new View.OnClickListener() {  

            @Override  
            public void onClick(View v) {  
                // TODO Auto-generated method stub  
                tv.startAnimation(scaleAnimation);  
            }  
        });  

    }  

}  

(1)通過(guò) scaleAnimation = AnimationUtils.loadAnimation(this, R.anim.scaleanim);從 XML 文件中獲取動(dòng)畫 (2)利用 startAnimation 將動(dòng)畫傳遞給指定控件顯示。

至此,本文就結(jié)束了,下篇將講述有關(guān)插值器的相關(guān)屬性及意義。

下面就是源碼下載了,源碼中包含兩部分內(nèi)容:

1、Harvic_animation_demo 工程:是第七部分的實(shí)例源碼;

2、tryAlpha_xml 工程:是前六節(jié)動(dòng)作代碼的集合,包含了前六小節(jié)里的所有代碼及動(dòng)畫定義。

源碼下載地址:http://download.csdn.net/detail/harvic880925/8032579

請(qǐng)大家尊重原創(chuàng)者版權(quán),轉(zhuǎn)載請(qǐng)標(biāo)明出處:http://blog.csdn.net/harvic880925/article/details/39996643 謝謝!