播放使用VideoView多个视频 [英] Playing multiple videos using VideoView

查看:689
本文介绍了播放使用VideoView多个视频的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在矢量视频列表{HTTP://a/video1.mp4, HTTP://a/video2.mp4 HTTP://a/video3.mp4 HTTP ://a/video4.mp4 HTTP://a/video5.mp4 ,的http://a/video6.mp4 }
我想打所有的视频​​之一后采用了Android原生播放器VideoView另一个。
请为我提供样品code实现相同的。

I have kept a list of videos in vector {http://a/video1.mp4, http://a/video2.mp4, http://a/video3.mp4, http://a/video4.mp4, http://a/video5.mp4, http://a/video6.mp4} I want to play all the videos one after the another using the Android native player VideoView. Kindly provide me the sample code to implement the same.

亲切问候,

CB

推荐答案

在您VideoView设置MediaPlayer.OnCompletionListener。当视频完成你的监听器将被调用,这样你就可以在你的矢量更改视频URI到下一个上。

Set a MediaPlayer.OnCompletionListener on your VideoView. Your listener will be called when the video is done, so you can change the video URI to the next on in your Vector.

这篇关于播放使用VideoView多个视频的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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