0

I trying to make mini IPTV app. I'm using VLCLib and sample from https://code.videolan.org/videolan/libvlc-android-samples/-/blob/master/java_sample/src/main/java/org/videolan/javasample/JavaActivity.java

But I have problem with loading speed (buffer maybe). It took 3-4sec to start another channel, also the same delay is for first load.

I'm using HLS (unadaptive) over http.

I have tried many options and my starting onCreate media creator look`s like

ArrayList<String> options = new ArrayList<>();
options.add("--drop-late-frames");
options.add("--skip-frames");
options.add("--clock-jitter=1");
options.add("--no-lua");
options.add("--avcodec-threads=2");
options.add("--avcodec-hw=any");
options.add("--avcodec-fast");
options.add("--avcodec-skip-idct=4");
options.add("--avcodec-skip-frame=3");
mLibVLC = new LibVLC(getApplicationContext(), options);
mMediaPlayer = new MediaPlayer(mLibVLC);

Video start/channel change

mMediaPlayer.detachViews();
mMediaPlayer.attachViews(mVideoLayout, null, ENABLE_SUBTITLES, USE_TEXTURE_VIEW);

final Media media = new Media(mLibVLC, Uri.parse(videoUrl));

mMediaPlayer.setMedia(media);
mMediaPlayer.setEventListener(mPlayerListener);
media.release();
mMediaPlayer.play();

Maybe someone have any minds how to speed up loading time?

P.S. This not worked for me Reduce delay when playing rtp stream with libvlc on Android

Psychical
  • 1
  • 1
  • Can you reproduce the same behavior with the official VLC android app? – mfkl Oct 20 '20 at 01:53
  • Can you try with a libvlc 4 nightly build? – mfkl Oct 20 '20 at 01:54
  • @mfkl Yes, it works perfect video start till 1sec in official app – Psychical Oct 20 '20 at 10:36
  • well then share full logs, including which version of the app and of libvlc you tried – mfkl Oct 20 '20 at 10:58
  • I have tried: "org.videolan.android:libvlc-all:3.3.1" "org.videolan.android:libvlc-all:3.3.4" also tried to build my own "libvlc-armv7-3.3.4.aar" but every time the same... I add logs then I press "next channel" - https://pastebin.com/L9cBtys6 – Psychical Oct 20 '20 at 11:31
  • What is the VLC android app versions? Please share full logs for both cases – mfkl Oct 20 '20 at 11:39
  • I have tried on VLC 3.3.1 official app. Also -vv log with 'org.videolan.android:libvlc-all:3.3.4' for my onw app - https://pastebin.com/SH8SF6MT – Psychical Oct 20 '20 at 11:51
  • Solved it by changing LibVLC to ExoPlayer... – Psychical Nov 02 '20 at 18:24

0 Answers0