Custom Video Player is a library with simple and clean controllers that can embedded anywhere in Android Applications. It can play single or multiple videos from URL's. Added auto mute, auto play to manage video player. Customised controllers and methods.
Add to layout<com.pavanpathro.custom_video_player.CustomVideoPlayer
android:id="@+id/customVideoPlayer"
android:layout_width="match_parent"
android:layout_height="300dp" />
Initialise Video Player
CustomVideoPlayer customVideoPlayer = findViewById(R.id.customVideoPlayer);
Single Video
customVideoPlayer.setMediaUrl("https://www.rmp-streaming.com/media/bbb-360p.mp4");
Multi Video
List<String> listOfVideos = new ArrayList<>();
listOfVideos.add("http://mirrors.standaloneinstaller.com/video-sample/jellyfish-25-mbps-hd-hevc.3gp");
listOfVideos.add("http://mirrors.standaloneinstaller.com/video-sample/star_trails.mkv");
listOfVideos.add("https://www.rmp-streaming.com/media/bbb-360p.mp4");
customVideoPlayer.setMediaUrls(listOfVideos);
Auto Mute (Default - false)
customVideoPlayer.enableAutoMute(true);
Auto Play (Default - true)
customVideoPlayer.enableAutoPlay(false);
Manage Controllers (Default - false)
customVideoPlayer.hideControllers(true);
Example
customVideoPlayer.setMediaUrls(listOfVideos)
.enableAutoMute(false)
.enableAutoPlay(false)
.hideControllers(false)
.setOnPlaybackListener(this)
.build();
Video Controllers
Play
customVideoPlayer.play();
Pause
customVideoPlayer.pause();
Stop
customVideoPlayer.stop();
Samples
Pavan Kumar Patruni (Email - [email protected])