正在处理本机描述应用程序,需要访问映像并将其转换为base64。
.then(function(selection) {
selection.forEach(function (selected) {
imageSourceModule
.fromAsset(selected)
.then((imageSource) => {
var imageBase64 = imageSource.toBase64String("jpg",60);
console.log(imageBase64);
我在fromAsset
中遇到了同样的问题,我通过这样做解决了它。
<application
...
android:requestLegacyExternalStorage="true"
...
</application>