EFQRCode icon indicating copy to clipboard operation
EFQRCode copied to clipboard

生成二维码时,选择相册里的gif图作为水印图片,不能生成gif图片

Open tc976562936 opened this issue 2 years ago • 0 comments

检查清单

  • [x] 我已阅读 README.md,但没找到我需要的信息。
  • [x] 我已查看 已知的问题,但没有相似的提问/请求。

问题描述

选择相册里的gif图作为水印图片,EFImage为normal成了普通照片

展开讲讲

在从相册里选择照片的didFinishPickingMediaWithInfo回调方法里, if let imageUrl = info[.referenceURL] as? URL, let asset = PHAsset.fetchAssets(withALAssetURLs: [imageUrl], options: nil).lastObject { images = selectedAlbumPhotosIncludingGifWithPHAssets(assets: [asset]) } asset为nil,images的count为0,导致不走底下的方法 if let tryGIF = images.first(where: { $0.value?.isGIF == true }) { watermark = tryGIF.value! }

重现步骤

xcode14.1 ios16.1.1 Swift5 EFQRCode6.2.1

其他信息

WeChat3fc0444585c6453b5b4746141b52b33c

tc976562936 avatar Dec 19 '22 08:12 tc976562936