+1 同样的问题,使用bitmap方式,在Android11上也是出现这个问题
分享异常(android11 微信版本7.0.20),图片分享只能使用setImagePath方法?https://developers.weixin.qq.com/doc/oplatform/Mobile_App/Share_and_Favorites/Android.html 一加8 IN 2010 , 微信版本7.0.20(微信版本7.0.19及以下无此问题) 小米 MI 10 ,微信版本7.0.20 (微信版本7.0.19及以下无此问题) [图片] //代码 if (api != null && api.isWXAppInstalled()) { Bitmap bitmap = bitmapBean.bitmap; WXImageObject imageObject = new WXImageObject(bitmap); WXMediaMessage mediaMessage = new WXMediaMessage(); mediaMessage.mediaObject = imageObject; Bitmap thumBitmap = Bitmap.createScaledBitmap(bitmap, 140, 303, true); bitmap.recycle(); mediaMessage.thumbData = bitmapToByteArray(thumBitmap, true); SendMessageToWX.Req req = new SendMessageToWX.Req(); req.transaction = "img"; req.message = mediaMessage; req.scene = bitmapBean.scene; api.sendReq(req); } else { ToastUtils.show("未安装微信"); }
2020-11-26