draw() {
const w = 300
let h = 200
const dpr = wx.getSystemInfoSync().pixelRatio
wx.createSelectorQuery().select('#myVideo').context(res => {
console.log('select video', res)
const video = this.video = res.context
wx.createSelectorQuery().selectAll('#cvs1').node(res => {
console.log('select canvas', res)
const ctx1 = res[0].node.getContext('2d')
res[0].node.width = w * dpr
res[0].node.height = h * dpr
setInterval(() => {
ctx1.drawImage(video, 0, 0, 960, 720, 0, 0, h * dpr, w * dpr);
}, 1000 / 24)
}).exec()
}).exec()
},
请具体描述问题出现的流程,并提供能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。
mp4格式视频开发工具正常,客户端mp4\m3u8均不行