MPMoviePlayerController从流视频获取缩略图? [英] MPMoviePlayerController Getting Thumbnail from Streaming Video?

查看:251
本文介绍了MPMoviePlayerController从流视频获取缩略图?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试从流式视频中获取一个视频缩略图,当将其触摸到按钮时.我都用过;

I'm trying to get a Video Thumbnail from Streaming Video when touched to a Button. I've used both;

- (UIImage *)thumbnailImageAtTime:(NSTimeInterval)playbackTime timeOption:(MPMovieTimeOption)option
- (void)requestThumbnailImagesAtTimes:(NSArray *)playbackTimes timeOption:(MPMovieTimeOption)option

但是每次返回的图像为空,或者在下面出现错误;

But everytime, returned image is null, or getting error below;

错误域= AVFoundationErrorDomain代码= -11838操作已停止" UserInfo = 0x7ac5560 {NSLocalizedFailureReason =该介质不支持该操作.NSUnderlyingError = 0x7a82ea0操作无法完成.(OSStatus错误-12435.) ",NSLocalizedDescription =操作已停止}

Error Domain=AVFoundationErrorDomain Code=-11838 "Operation Stopped" UserInfo=0x7ac5560 {NSLocalizedFailureReason=The operation is not supported for this media., NSUnderlyingError=0x7a82ea0 "The operation couldn’t be completed. (OSStatus error -12435.)", NSLocalizedDescription=Operation Stopped}

是否有从流视频中获取缩略图的运气? 谢谢.

is there any luck to get thumbnail from streaming video? Thanks.

推荐答案

您必须先下载整个视频,然后才能获得支持API的请求...因为它表示API不支持从远程媒体获取支持

You will have to download the whole video before you can get a thumb with API requests...as it says the API does not support getting thumbs from remote media

这篇关于MPMoviePlayerController从流视频获取缩略图?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆