交互
更新时间:2021-06-17
UserInteraction
此类封装application[友情提示:与Globalfield字段相反]
Fields | |
---|---|
UserInteraction | disableAccompany 按下跟随功能是否开启 |
UserInteraction | disableAll 主开关, 开启全部手势 |
UserInteraction | disableClick 点击 |
UserInteraction | disableDoubleClick 双击 |
UserInteraction | disablePinch 捏合 |
UserInteraction | disableScroll 滑动 |
UserInteraction | disableSingleFingerScroll 单指平移 |
UserInteraction | disableTwoFingerScroll 双指旋转 |
UserInteraction | enableTouchZone 开启热区 |
Public methods | |
---|---|
UserInteraction | AllUserInteractionDemo()所有json全局字段示例 |
AllUserInteractionDemo
全部手势示例
sample:
"userInteraction":
{
"disableAll": 0,
"disablePinch": 0,
"disableClick": 0,
"disableScroll": 0,
"disableDoubleClick": 0,
"disableSingleFingerScroll": 0,
"disableTwoFingerScroll": 0,
"enableTouchZone":1
},
*[0 开启 1 关闭 -> "enableTouchZone":(1 开启 0关闭)]
disableAccompany
version 20
按下跟随功能是否开启。(0:开启,1:不开启),slam下为保证跟踪效果,需要修改该字段为1
sample:
"disableAccompany":0
开启该字段后,按下跟随效果生效。
disableAll
version 8
主开关。开启全部手势
sample:
详见:AllUserInteractionDemo()
disableClick
version 8
点击
sample:
详见:AllUserInteractionDemo()
disableDoubleClick
version 8
双击
sample:
详见:AllUserInteractionDemo()
disablePinch
version 8
捏合
sample:
详见:AllUserInteractionDemo()
disableScroll
version 8
滚动
sample:
详见:AllUserInteractionDemo()
disableSingleFingerScroll
version 8
单指平移
sample:
详见:AllUserInteractionDemo()
disableTwoFingerScroll
version 8
双指旋转
sample:
详见:AllUserInteractionDemo()
enableTouchZone
version 8
开启热区。(热区是针对单个模型文件做控制的,开启可实现功能:1、场景中存在多个模型,对单个模型做手势控制;2.缩放极致限制)
sample:
详见:AllUserInteractionDemo()
开启该字段后,还需在需要热区的节点下开启以下三个字段,并根据需求配置参数大小:
"minScale": 0.0001,
"maxScale": 10000,
"touchZone":120,