示例代码:
如何在一个活动中播放这两个视频
public class Two_videos extends Activity
{
VideoView video1,video2;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.two_video);
VideoView video1= (VideoView) findViewById(R.id.video1);
video1.setVideoPath("/mnt/sdcard/Movies/com.bnb.giggle/IMG_20130415184609.mp4");
video1.start();
VideoView video2= (VideoView) findViewById(R.id.video2);
video2.setVideoPath("/mnt/sdcard/Movies/com.bnb.giggle/IMG_20130415184608.mp4");
video2.start();
}
}
不能同时播放两个视频.
最佳答案
原文链接:https://www.f2er.com/android/430843.html