![ios – 崩溃 – [AVPlayerItem _attachToPlayer:] AVPlayerItem不能与多个AVPlayer实例相关联,第1张 ios – 崩溃 – [AVPlayerItem _attachToPlayer:] AVPlayerItem不能与多个AVPlayer实例相关联,第1张](/aiimages/ios+%E2%80%93+%E5%B4%A9%E6%BA%83+%E2%80%93+%5BAVPlayerItem+_attachToPlayer%EF%BC%9A%5D+AVPlayerItem%E4%B8%8D%E8%83%BD%E4%B8%8E%E5%A4%9A%E4%B8%AAAVPlayer%E5%AE%9E%E4%BE%8B%E7%9B%B8%E5%85%B3%E8%81%94.png)
Crashlytics报道了大约一半的应用程序不重要的崩溃用户,即做背景音乐或AirPlay.应用程序播放HLS视频流,并在后台切换到仅音频版本.
任何想法有什么问题,或为什么会有多个AVPlayer实例从我的单身玩家类?
谢谢!
Exception Type:NSinvalidargumentexceptionReason:An AVPlayerItem cannot be associated with more than one instance of AVPlayerFatal ExceptionLatest Crash: 4/06/2013 at 8:48:46 UTC+02000 CoreFoundation __exceptionPreprocess + 1621 libobjc.A.dylib objc_exception_throw + 302 AVFoundation -[AVPlayerItem _attachtoplayer:] + 1883 AVFoundation -[AVPlayer _attachItem:andPerformOperation:withObject:] + 3364 AVFoundation -[AVPlayer _insertItem:afterItem:] + 265 AVFoundation -[AVQueuePlayer insertItem:afterItem:] + 1366 MediaPlayer __block_global_4 + 5207...libdispatch.dylib _dispatch_call_block_and_release + 1014解决方法 似乎通过在设置新的URL之前明确地停止播放来解决.
[movIEPlayer stop];movIEPlayer.movIESourceType = MPMovIESourceTypestreaming;[movIEPlayer setContentURL:[NSURL URLWithString:[vIDeos objectForKey:quality]]];总结
以上是内存溢出为你收集整理的ios – 崩溃 – [AVPlayerItem _attachToPlayer:] AVPlayerItem不能与多个AVPlayer实例相关联全部内容,希望文章能够帮你解决ios – 崩溃 – [AVPlayerItem _attachToPlayer:] AVPlayerItem不能与多个AVPlayer实例相关联所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)