You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I use FMPhotoPicker select video asset, this method func requestAVAsset(asset: PHAsset, complete: @escaping (AVAsset?) -> Void) always return a nil asset and the player won't be initialized, tap play button and nothing happends , a fews seconds later the app crash because some UI modifications performed from a background thread, I try to fix first problem by adding an option to PHImageManager and it works:
let manager = PHImageManager.default()
let option = PHVideoRequestOptions()
option.isNetworkAccessAllowed = true
manager.requestAVAsset(forVideo: asset, options: option) { asset, audioMix, _ in
DispatchQueue.main.async {
complete(asset)
}
}
hope help, and the other problem I took a screenshot for your reference,hope useful:
The text was updated successfully, but these errors were encountered:
When I use FMPhotoPicker select video asset, this method
func requestAVAsset(asset: PHAsset, complete: @escaping (AVAsset?) -> Void)
always return a nil asset and the player won't be initialized, tap play button and nothing happends , a fews seconds later the app crash because some UI modifications performed from a background thread, I try to fix first problem by adding an option to PHImageManager and it works:hope help, and the other problem I took a screenshot for your reference,hope useful:
The text was updated successfully, but these errors were encountered: