How to Embed Vlc Media Player to My Android App

Is it possible to get the VLC player layout, complete with media player buttons and a seekbar etc..?

LibVLC for Android is not like ExoPlayer. It does not come with a companion UI class or anything like that. Therefore, you have to build your very own UI for it.

A very good starting point would be to use ExoPlayer's very own UI and customize it to your need. Then you need to do your own bindings and listeners for the buttons.

LibVLC will be responsible for playing the video and anything related to the task, but it does not have anything that delegates user interaction with it. You have to do it manually.

If you face issues controlling and putting LibVLC to use, then you need to thoroughly inspect the code of VLC for Android. They made everything open-source so that's already a great thing. Check VLC Android - Repository

Android VLC Embed vs Android VideoView

  1. What's the advantage (pros) and disadvantage (cons) of using Android VLC Embed vs. Android VideoView?
  • Advantage:

More features. VLC supports almost all media formats, hardware decoding. audio tracks, subtitles, chapter are also supported.

More integrated, simpler logic. You can easily get media information and cache them. The playback engine will proactively notify state changes and events, just register player event listening.

  • Disadvantage:

APK file size increas. If both arm64-v8a and armeabi-v7a are supported, it will increase more than 30MB.

Multiple instances are not perfect. For example, playing 2 videos at the same time is a hassle.


  1. Is VLC Embed stable?

Stable. Starting with VLC 2.0.x (now 3.0.x), I use the VLC library in my Android App. It runs steadily from Android 5.1 to Android 8.0. A small number of 4k h265 video playback is not normal, but can be resolved by displaying "Can not play".


  1. Anything I should be careful when switching existing VideoView to VLC?

To use LibVLC on Android The Medialibrary(org.videolan.medialibrary) is also required. You also need to note the licenses.



Related Topics



Leave a reply



Submit