下载视频Android的第一帧编程 [英] Download first frame of video android programmatically

查看:162
本文介绍了下载视频Android的第一帧编程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从一个服务器从我的Andr​​oid应用程序下载的视频文件的一帧。我不笏下载完整的视频在前面。使用该帧作为缩略图来显示给用户,这样,如果choosen由用户就可以下载。

I want to download a single frame of a video file from a server from my android application. I do not wat to download the full video at front. Use that frame as a thumbnail to display to the user, so that if choosen by user it can be downloaded.

推荐答案

的ffmpeg 可以使用此命令从视频流中创建缩略图:

ffmpeg can create a thumbnail from a video stream using this command:

ffmpeg -itsoffset -4  -i http://somevideosite/test.avi -vcodec mjpeg -vframes 1\
       -an -f rawvideo -s 320x240 thumb.jpg

要获得的ffmpeg 进入Android的似乎<一href="http://stackoverflow.com/questions/2645041/ffmpeg-for-a-android-using-tutorial-ffmpeg-and-android-mk">doable.

To get ffmpeg into android seems doable.

这篇关于下载视频Android的第一帧编程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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