iOS AVPlayer 不会播放有声读物,但 MPPLayerController 可以
我正在开发一个播客/有声读物应用程序。 AVPlayer 非常适合播放播客,但无法播放 audible.com 上的有声读物。它将在 MPMusicPlayer 中播放声音文件。这是专有格式的 b/c 吗?我只是想弄清楚是否需要完全重构我的应用程序以使用 mpmusicplayer 或按音频类型使用两个播放器。 谢谢!这个论坛太有帮助了!!
I'm developing a podcast/audiobook application. AVPlayer is working great for playing podcasts but won't play audiobook from audible.com. It will play audible files in MPMusicPlayer. Is that b/c of proprietary format? I'm just trying to figure out if I need to totally refactor my app to use mpmusicplayer or use both players by audio type.
THanks! This forum has been so helpful!!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
AV--- 类是较低级别的。有很多事情是由 MP 类自动处理的,当您使用 AVFoundation 中的类时,您必须自己完成这些事情。
在我的项目中,我尽可能使用 MPMoviePlayerController 和相关类,而不是使用 AVFoundation 类。节省了我很多时间。仅当 MediaPlayer 框架无法处理项目需求时,我才使用 AVFoundation 类。
在 Audible 有声读物的这种特定情况下,书籍或 MediaPlayer 框架正在处理的连接可能存在某种加密。
The AV--- classes are lower-level. There are a lot of things handled automatically by the MP--- classes that you have to do yourself when you use classes from AVFoundation.
In my projects, I use the MPMoviePlayerController and related classes instead of using the AVFoundation classes, whenever I can. Saves me a lot of time. Only when the project requirements can't be handled by the MediaPlayer framework do I use the AVFoundation classes.
In this specific case of audio books from Audible, it's likely that there's some encryption on the book or the connection that is being handled by the MediaPlayer framework.