图片选择png格式问题
发布于 5 年前 作者 liufang 15848 次浏览 来自 问答

机型:IOS

透明背景的png图片选择后,会把透明背景改成白色,可能是改为jpg格式了

安卓还是透明背景

3 回复
wx.chooseImage({
    count: 9,
    sizeType: ['original', 'compressed'],
    sourceType: ['album', 'camera'],
    success: (res) => {
        var tempFilePaths = res.tempFilePaths;
        this.setData({
            imgList: tempFilePaths
        })
    }
})
<block wx:key wx:for="{{imgList}}" wx:for-index="index">
    <view class="picWrapper" bindtap="handleGoToImgDetail" data-index="{{index}}">
        <image class="pic" src="{{imgList[index]}}" />
    </view>
</block>

就是普通的选择图片Api

麻烦上面的大哥及时反馈哈

你好,请提供一下能复现问题的简单代码示例。

回到顶部