图片压缩后,文件大小,尺寸没有变化,旋转方向确发生变化
代码片段
new Promise((resolve, reject) => {
uni.compressImage({
src: path,
quality: 60,
success: (compressRes) => {
console.log(compressRes)
resolve(compressRes.tempFilePath);
},
fail: (compressErr) => {
reject(compressErr)
}
})
}).then(rrr => {
console.log(rrr)
uni.getImageInfo({
src: rrr,
success: function (r) {
console.log("压缩后:",r)
}
})
})