M3D / M3D / Animation / AnimationPlayApi
Class: AnimationPlayApi
M3D.Animation.AnimationPlayApi
Memberof
M3D.Animation
Description
动画播放接口
Author
YF
Table of contents
Constructors
Properties
- bCollisionInited
- bCollisionInterruptFlg
- cameraMtx
- clipNormal
- clipPos
- clipVisible
- pAnimationPlayCBList
Methods
- calculatelRotationMtx
- calculatelTanslationMtx
- cameraRotation
- cameraScale
- cameraTargetPntToPosition
- cameraTranslation
- getCamera
- getCameraTargetPnt
- getFocalDistance
- getModelPlcMtx
- modelRotation
- modelScale
- modelTanslation
- play
- playAnimationImage
- playBegin
- playCamera
- playClipPlane
- playColor
- playEnd
- playScale
- playToolAnimation
- playVisible
- setCamera
- setModelPlcMtx
- setModelPlcMtxScale
- setTargetState
- updateView
- SAPlcPathToDispPlcPath
Constructors
constructor
• new AnimationPlayApi(): AnimationPlayApi
Returns
Memberof
AnimationPlayApi
Properties
bCollisionInited
• bCollisionInited: boolean
Description
干涉数据是否已经被初始化标志
Memberof
AnimationPlayApi
bCollisionInterruptFlg
• bCollisionInterruptFlg: boolean
Description
是否命令干涉检查标志
Memberof
AnimationPlayApi
cameraMtx
• cameraMtx: number[][]
Description
摄像机的矩阵,播放摄像机时将摄像机的位置先存入该变量,当位置、方向、缩放比例插值计算都完成时,一些设置到摄像机中
Memberof
AnimationPlayApi
clipNormal
• clipNormal: Vector3
Description
剖面的法向
Memberof
AnimationPlayApi
clipPos
• clipPos: number[]
Description
剖面的位置
Memberof
AnimationPlayApi
clipVisible
• clipVisible: boolean
Description
剖面的显示隐藏状态
Memberof
AnimationPlayApi
pAnimationPlayCBList
• pAnimationPlayCBList: AnimationPlayCBList
Description
附加的动画播放回调函数,要标准动画播放回调函数中,有些模块的内容不可访问,可以在各个模块注册与自己模块相关的动画播放回调函数
Memberof
AnimationPlayApi
Methods
calculatelRotationMtx
▸ calculatelRotationMtx(plcIdPath, fPivot, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
Returns
void
calculatelTanslationMtx
▸ calculatelTanslationMtx(plcIdPath, fPivot, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
Returns
void
cameraRotation
▸ cameraRotation(plcIdPath, fPivot, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
Returns
void
Description
相机旋转
Memberof
AnimationPlayApi
cameraScale
▸ cameraScale(plcIdPath, fPivot, fMtxAA, iCamType, scene): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
iCamType | number |
scene | Scene |
Returns
void
cameraTargetPntToPosition
▸ cameraTargetPntToPosition(plcIdPath, fTarget, fRotMatrix, fPosition, scene): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fTarget | number[] |
fRotMatrix | number[][] |
fPosition | number[] |
scene | Scene |
Returns
void
cameraTranslation
▸ cameraTranslation(plcIdPath, fPivot, fMtxAA): void
Parameters
| Name | Type | Description |
|---|---|---|
plcIdPath | string | 动画路径 |
fPivot | number[] | |
fMtxAA | number[][] |
Returns
void
Description
相机转换
Memberof
AnimationPlayApi
getCamera
▸ getCamera(plcIdPath, fScale, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fScale | number[] |
fMtxAA | number[][] |
Returns
void
Deprecated
Memberof
AnimationPlayApi
getCameraTargetPnt
▸ getCameraTargetPnt(plcIdPath, fTargetPnt): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fTargetPnt | number[] |
Returns
void
Deprecated
Memberof
AnimationPlayApi
getFocalDistance
▸ getFocalDistance(plcIdPath, scene): number
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
scene | Scene |
Returns
number
Deprecated
Memberof
AnimationPlayApi
getModelPlcMtx
▸ getModelPlcMtx(plcIdPath, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fMtxAA | number[][] |
Returns
void
modelRotation
▸ modelRotation(plcIdPath, fPivot, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
Returns
void
modelScale
▸ modelScale(plcIdPath, fPivot, fMtxAA, fScale): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
fScale | number[] |
Returns
void
modelTanslation
▸ modelTanslation(plcIdPath, fPivot, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
Returns
void
play
▸ play(type, plcIdPath, fPivot, fMtxAA): boolean
Parameters
| Name | Type |
|---|---|
type | number |
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
Returns
boolean
playAnimationImage
▸ playAnimationImage(plcIdPath, name, fPos, fScale, bOnOffFlg): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
name | string |
fPos | number[] |
fScale | number[] |
bOnOffFlg | boolean |
Returns
void
playBegin
▸ playBegin(): void
Returns
void
playCamera
▸ playCamera(plcIdPath, type, fPivot, fMtxAA, iCamType, scene): boolean
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
type | number |
fPivot | number[] |
fMtxAA | number[][] |
iCamType | number |
scene | Scene |
Returns
boolean
playClipPlane
▸ playClipPlane(type, plcIdPath, name, fNormal, fPos, bOnOff): void
Parameters
| Name | Type |
|---|---|
type | number |
plcIdPath | string |
name | string |
fNormal | number[] |
fPos | number[] |
bOnOff | boolean |
Returns
void
playColor
▸ playColor(plcIdPath, name, fColor, scene): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
name | string |
fColor | Vector3 |
scene | Scene |
Returns
void
playEnd
▸ playEnd(): void
Returns
void
Description
播放结束
Memberof
AnimationPlayApi
playScale
▸ playScale(type, plcIdPath, fPivot, fMtxAA, fScale): boolean
Parameters
| Name | Type |
|---|---|
type | number |
plcIdPath | string |
fPivot | number[] |
fMtxAA | number[][] |
fScale | number[] |
Returns
boolean
playToolAnimation
▸ playToolAnimation(nType, plcIdPath, strToolPath, strParentPath): void
Parameters
| Name | Type |
|---|---|
nType | number |
plcIdPath | string |
strToolPath | string |
strParentPath | string |
Returns
void
playVisible
▸ playVisible(plcIdPath, name, bOnOff, fTran, scene): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
name | string |
bOnOff | boolean |
fTran | number |
scene | Scene |
Returns
void
setCamera
▸ setCamera(plcIdPath, fScale, fMtxAA, scene): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fScale | number[] |
fMtxAA | number[][] |
scene | Scene |
Returns
void
Description
设置相机
setModelPlcMtx
▸ setModelPlcMtx(plcIdPath, fMtxAA): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fMtxAA | number[][] |
Returns
void
setModelPlcMtxScale
▸ setModelPlcMtxScale(plcIdPath, fMtxAA, fScale): void
Parameters
| Name | Type |
|---|---|
plcIdPath | string |
fMtxAA | number[][] |
fScale | number[] |
Returns
void
setTargetState
▸ setTargetState(vecTarget): void
Parameters
| Name | Type |
|---|---|
vecTarget | TargetObjectInfo[] |
Returns
void
updateView
▸ updateView(pBehaviorManager): void