如有不明白的可以加QQ:2354528292;wx: aichitudousien
更多教学视频请访问:https://space.bilibili.com/236087412
使用aframe加载模型,然后使用语音识别功能对模型进行控制,模型可做起跳,奔跑等动作,详细请看视频:
Three.js + 语音识别控制模型动画
<a-scene>
<div class="dropdown">
<el-select v-model="walkAnimation" placeholder="请选择">
<el-option v-for="(item, key) in animate" :key="key" :label="item" :value="key">
</el-option>
</el-select>
</div>
<div class="voice">
<el-button @click="startVoice" type="primary" round>{{ text }}</el-button>
</div>
<a-sky src="sky.jpg"> </a-sky>
<a-entity id="walker2" position="0 0 -5" visible="true">
<a-entity
gltf-model="model/dino.glb"
id="dino"
scale="1.5 1.5 1.5"
animation-mixer="clip:Idle"
rotation="0 90 0"
shadow="cast: true"
>
</a-entity>
</a-entity>
</a-scene>