小程序 canvas 画云存储的地址的图片怎么画?getImageInfo 好像不对
let bgUrl = ''
// canvas绘制网络图片需保存至本地
wx.getImageInfo({
src: '',//服务器返回的图片地址
success: function (res) {
console.log(res);
bgUrl = res.Path
},
fail: function (res) {
console.log(res);
}
});
ctx.drawImage(bgUrl, 0, 0, wigth, height);