CurveAnimation
类:曲线动画
Constructor
new Glodon.Bimface.Plugins.Animation.CurveAnimation(curveAnimationConfig)
构造曲线动画
Parameters:
| Name | Type | Description | 
|---|---|---|
| curveAnimationConfig | Glodon.Bimface.Plugins.Animation.CurveAnimationConfig | 曲线动画配置项  | 
Methods
getCurves()
获取曲线动画的曲线对象
Returns:
| Type | Description | 
|---|---|
| Array | 曲线对象的数组  | 
getId()
获取曲线动画ID
Returns:
| Type | Description | 
|---|---|
| String | 曲线动画ID  | 
getLoop()
获取曲线动画是否循环
Returns:
| Type | Description | 
|---|---|
| Boolean | 曲线动画是否循环  | 
getSpeed()
获取曲线动画速度
Returns:
| Type | Description | 
|---|---|
| Number | 动画速度  | 
getTime()
获取曲线动画时间
Returns:
| Type | Description | 
|---|---|
| Number | 动画时间,单位为毫秒  | 
getType()
获取曲线动画类型
Returns:
| Type | Description | 
|---|---|
| String | 曲线动画类型  | 
pause()
暂停动画
play()
播放动画
setLoop(loop)
设置曲线动画是否循环
Parameters:
| Name | Type | Description | 
|---|---|---|
| loop | Boolean | 曲线动画是否循环  | 
setSpeed(speed)
设置曲线动画速度
Parameters:
| Name | Type | Description | 
|---|---|---|
| speed | Number | 动画速度,每秒前进的距离,距离单位与场景设置单位一致  | 
setTime(time)
设置曲线动画时间
Parameters:
| Name | Type | Description | 
|---|---|---|
| time | Number | 动画时间,单位为毫秒  | 
setType(type)
设置曲线动画类型
Parameters:
| Name | Type | Description | 
|---|---|---|
| type | String | 动画类型,“trail”为轨迹,“flow”为流动,默认为“trail”  | 
stop()
停止动画