在线时间:8:00-16:00
132-9538-2358
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
从基础库 1.6.0 开始,本接口停止维护,请使用 wx.createInnerAudioContext 代替
暂停正在播放的语音。再次调用 wx.playVoice 播放同一个文件时,会从暂停处开始播放。如果想从头开始播放,需要先调用 wx.stopVoice。
wx.startRecord({ success (res) { const tempFilePath = res.tempFilePath wx.playVoice({ filePath: tempFilePath }) setTimeout(() => { wx.pauseVoice() }, 5000) } })
评论
请发表评论