# VLC stumbling every 10 seconds playing *mkv or *avi videos



## free-and-bsd (Jan 8, 2014)

Hi,

This is the problem I'm seeing in VLC since the last update: it stumbles every 10-15 seconds when playing *.mkv and *.avi videos. This stumbling is very much like the one you used to have with LPs when an LP has a scratch and the needle comes over the scratch. Though this doesn't happen when playing DVDs and MP4 files, nor, interestingly enough, when calling the cvlc (dummy interface) from terminal to play the same files that cause stumbling in vlc/qvlc/svlc/rvlc.

Here's the "stumbling moment" output appearing in the terminal when calling vlc (not cvlc) from command line:


```
[0x81208a110] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1177 ms)
[0x81208a110] main input error: ES_OUT_RESET_PCR called
[0x81208a110] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1196 ms)
[0x81208a110] main input error: ES_OUT_RESET_PCR called
[0x81208a110] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1240 ms)
[0x81208a110] main input error: ES_OUT_RESET_PCR called
[0x81208a110] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1247 ms)
```

It is the version


```
VLC media player 2.1.2 Rincewind (revision 2.1.2-0-ga4c4876)
```

It definitely wasn't there in the previous version.

Here are the config_uration_ options from the /var/db/ports/multimedia_vlc:

```
OPTIONS_FILE_SET+=A52
OPTIONS_FILE_UNSET+=AALIB
OPTIONS_FILE_UNSET+=ASS
OPTIONS_FILE_SET+=AVAHI
OPTIONS_FILE_UNSET+=CACA
OPTIONS_FILE_SET+=DBUS
OPTIONS_FILE_UNSET+=DEBUG
OPTIONS_FILE_UNSET+=DIRAC
OPTIONS_FILE_SET+=DOCS
OPTIONS_FILE_SET+=DTS
OPTIONS_FILE_SET+=DVDNAV
OPTIONS_FILE_SET+=DVDREAD
OPTIONS_FILE_SET+=FAAD
OPTIONS_FILE_SET+=FLAC
OPTIONS_FILE_UNSET+=FLUID
OPTIONS_FILE_SET+=FRIBIDI
OPTIONS_FILE_UNSET+=GME
OPTIONS_FILE_UNSET+=GNOMEVFS
OPTIONS_FILE_SET+=GNUTLS
OPTIONS_FILE_UNSET+=GOOM
OPTIONS_FILE_SET+=HTTPD
OPTIONS_FILE_UNSET+=JACK
OPTIONS_FILE_UNSET+=LIBBLURAY
OPTIONS_FILE_UNSET+=LIBSSH2
OPTIONS_FILE_UNSET+=LIRC
OPTIONS_FILE_UNSET+=LIVEMEDIA
OPTIONS_FILE_SET+=LUA
OPTIONS_FILE_SET+=MAD
OPTIONS_FILE_SET+=MATROSKA
OPTIONS_FILE_UNSET+=MODPLUG
OPTIONS_FILE_SET+=MPEG2
OPTIONS_FILE_UNSET+=MTP
OPTIONS_FILE_UNSET+=MUSEPACK
OPTIONS_FILE_UNSET+=NCURSES
OPTIONS_FILE_SET+=NLS
OPTIONS_FILE_UNSET+=NOTIFY
OPTIONS_FILE_UNSET+=NO_DVD
OPTIONS_FILE_SET+=OGG
OPTIONS_FILE_UNSET+=OPTIMIZED_CFLAGS
OPTIONS_FILE_SET+=OPUS
OPTIONS_FILE_SET+=PNG
OPTIONS_FILE_UNSET+=PULSEAUDIO
OPTIONS_FILE_SET+=QT4
OPTIONS_FILE_SET+=REALAUDIO
OPTIONS_FILE_UNSET+=RUNROOT
OPTIONS_FILE_UNSET+=SAMBA
OPTIONS_FILE_SET+=SAMPLERATE
OPTIONS_FILE_UNSET+=SCHROED
OPTIONS_FILE_SET+=SDL
OPTIONS_FILE_UNSET+=SERVER_ONLY
OPTIONS_FILE_UNSET+=SHOUTCAST
OPTIONS_FILE_UNSET+=SIDPLAY
OPTIONS_FILE_SET+=SKINS
OPTIONS_FILE_SET+=SPEEX
OPTIONS_FILE_SET+=STREAM
OPTIONS_FILE_UNSET+=SVG
OPTIONS_FILE_SET+=TAGLIB
OPTIONS_FILE_SET+=THEORA
OPTIONS_FILE_SET+=TWOLAME
OPTIONS_FILE_UNSET+=UPNP
OPTIONS_FILE_SET+=V4L
OPTIONS_FILE_UNSET+=VAAPI
OPTIONS_FILE_SET+=VCD
OPTIONS_FILE_SET+=VORBIS
OPTIONS_FILE_SET+=X11
OPTIONS_FILE_SET+=X264
OPTIONS_FILE_UNSET+=ZVBI
```


----------



## free-and-bsd (Jan 11, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

Is there any other information needed that I can provide?


----------



## free-and-bsd (Jan 28, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

No replies in this post might seem to indicate that this is some compile-time error happening only in my installation. I can confirm now that this is not so.

This behaviour is further confirmed by another build of latest VLC (using Qt4 GUI) done recently in connection with the upgrade of one of my installations from 9.2-STABLE to 10.0-RELEASE. The installed ports had to be rebuilt because of the system libraries versions having changed. This "hiccup" of VLC mediaplayer is still noticeable also in this build of VLC when playing *mkv or *avi files, yet MP4 or DVD are safe.  
Although the history of bugs submitted in the past seem to track this issue to h.264 codec, this doesn't explain why, then, everything is fine when VLC is run using cvlc command line.


----------



## ybungalobill (Apr 20, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

I can confirm that I have exactly the same problem. Playing the video barely scratches the computational or I/O capacity of my machine, and it didn't existed in some of the previous versions (with the same video), so it must be a bug.

I tried maxing the buffering time (to 60 seconds); it reduced the problem, but didn't solve it. I don't know of any solution.


----------



## free-and-bsd (Apr 22, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

Well the solution so far has been to run vlc from terminal using `cvlc` command for *.mkv and *avi files. Obviously this has nothing to do with the amount of memory/cpu resources.

...Well, on the bright side of it, running it as `cvlc ... [FILE]` encourages to learn hot keys for vlc and in general, the minimalistic style. Then, too, there is MPlayer which does it all fine.


----------



## nox@ (Apr 28, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

Hi!

I brought this up on #videolan yesterday and a fix was committed to vlc git head which I then backported and committed to the vlc version in ports.  So I _hope_ this is fixed now...

References: http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/186093 http://git.videolan.org/gitweb.cgi/vlc. ... f75a75b46b http://svnweb.freebsd.org/changeset/ports/352445


----------



## free-and-bsd (Apr 30, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

Thanks a lot! ))


----------



## free-and-bsd (Aug 20, 2014)

*It's back now. And not alone, but along with video distortio*

Well well well... It's back now in the last build, and even with some graphics distortions . It's beyond mistake, for the file I've been trying it on remains the same.


----------



## zspider (Aug 20, 2014)

*Re: VLC stumbling every 10 seconds playing *mkv or *avi vide*

Same problem, MKV's are nearly useless, the video and audio stops and starts, glitches out about every 5 seconds. Also MOV files sometimes fail to load any video and sometimes causes VLC to crash outright.


----------



## tankist02 (Apr 7, 2017)

More than 2 years later - still the same issue: .mkv files are unusable, other types sometimes loose sync, but not as bad. Does anybody on FreeBSD use VLC at all? When started from console I get the following output:


```
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1000 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a963200] co located POCs unavailable
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a963200] co located POCs unavailable
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1016 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a963200] co located POCs unavailable
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a963200] co located POCs unavailable
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1236 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1383 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1469 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961e00] co located POCs unavailable
[h264 @ 0x81a963200] Missing reference picture, default is 65654
[h264 @ 0x81a961e00] co located POCs unavailable
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1491 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961400] co located POCs unavailable
[h264 @ 0x81a963200] co located POCs unavailable
[h264 @ 0x81a962800] co located POCs unavailable
[000000080ea12050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1523 ms)
[000000080ea12050] core input error: ES_OUT_RESET_PCR called
[000000081a960550] avcodec decoder: Using NVIDIA VDPAU Driver Shared Library  375.39  Tue Jan 31 19:13:14 PST 2017 for hardware decoding.
[h264 @ 0x81a961400] co located POCs unavailable
```


Would be happy to provide further details to resolve the issue.


----------



## rigoletto@ (Apr 7, 2017)

I had the same problems with VLC on FreeBSD and Linux (several distros), my solution was multimedia/mpv. However, multimedia/umplayer and multimedia/mpc-qt are also good.


----------



## tankist02 (Apr 10, 2017)

I can confirm - tried VLC with a couple of .mkv files on a fully updated Fedora 25. VLC also looses sync if I jump forward. Not as bad as on FreeBSD, but still not quite usable. I guess it is fine to remove VLC and use something else. My choices are multimedia/mpv and multimedia/smplayer. Will take a look at multimedia/umplayer,  thank you for the hint.


----------



## Wulfgeat Simonson (Jul 8, 2017)

Hi folks,

Same troubles with MKV and AVI

When using vlc from packages am getting constant :


```
[000000080b80d050] core input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1000 ms)
[000000080b80d050] core input error: ES_OUT_RESET_PCR called
[000000081b9ba110] vaapi_drm generic error: Could not access rendering device: m
[h264 @ 0x81163b400] co located POCs unavailable
[h264 @ 0x81163be00] co located POCs unavailable
```

Same thing with cvlc no difference, mplayer does work but occasionally has audio lag.

Have not tried mpv, mainly because it wants to reinstall my nvidia drivers and I don't want to bring the machine down at the moment.

Tried umplayer from packages and am getting absolutely smooth playback, no stuttering, no audio lag. 
Highly recommend it, it seems to be working for me with resolutions from 360p up to 4K, with many different bit rates.

It is disappointing to see vlc bugs are back in the port after being fixed since I have used vlc for so long, that said umplayer seems quite nice.


----------



## Deleted member 45312 (Jul 8, 2017)

VLC 2.2.6 Umbrella works well for me with my Nvidia GT610 video adapter. Nvidia VDPAU hardware decoding works now, this was not the case before.
I am using quarterly branch 2017Q3 on FreeBSD 11.0-RELEASE-p9 amd64.


----------



## Deleted member 30996 (Jul 19, 2017)

Wulfgeat Simonson said:


> Same troubles with MKV and AVI



I'm using vlc-qt4 2.2.6 Umbrella built from ports on both my FreeBSD 11.0-RELEASE-p9 laptops and don't have any problems whatsoever playing .avi files on either. I tried several different files all full screen, have one running now, and they played without any lag or stuttering.

One box has an Intel i945GM and the other a ATI Mobility Radeon HD 4250.

I'd have to dig through my flash drives to find a .mkv file but am pretty sure the last one I tried played alright.


----------



## SirDice (Jul 19, 2017)

Note that MKV or AVI doesn't say anything about the codecs being used. Both are container formats and can consist of a wide variety of audio and video codecs. Not all codecs work equally well, there are for example, several MS specific codecs that decode awfully on anything else besides Windows.


----------



## aimeec1995 (Aug 24, 2017)

I don't know what VLC's deal is. It just sucks ass in freebsd.
It won't scale half my videos right and I have to adjust the zoom. I also experience the stumbling and visual distortions as well as just low fps.


----------



## aimeec1995 (Aug 24, 2017)

lebarondemerde said:


> I had the same problems with VLC on FreeBSD and Linux (several distros), my solution was multimedia/mpv. However, multimedia/umplayer and multimedia/mpc-qt are also good.



Those are good but they won't let me select non default sub-titles like VLC does. 
Not that I can see, anyways.


----------



## rigoletto@ (Aug 24, 2017)

I currently use multimedia/mpv, and you can easily set default audio and subtitle language. It is in the mpv(1) manual, `alang`and `slang`.

You can even have the subtitles automatically downloaded using multimedia/py-subliminal.
HERE is a example.


----------



## Minbari (Aug 24, 2017)

aimeec1995 said:


> I don't know what VLC's deal is. It just sucks ass in freebsd.
> It won't scale half my videos right and I have to adjust the zoom. I also experience the stumbling and visual distortions as well as just low fps.



Did you try install/reinstall him from ports and chose diffrent settings there (make config-recursive)? I build mine from ports because it fail to load embedded subtitles and then I lock the package so when I'm running upgrade, pkg won't rewrite him, though most of my software is installed from ports not with pkg.


----------



## Deleted member 30996 (Aug 25, 2017)

I tried Escape From New York using multimedia/vlc tonight on my FreeBSD 11.1-RELEASE-p1 T61 with a nVIDIA Quadro NVS 140M and 256MB shared memory and it wouldn't have played any smoother on my Flatscreen TV from a Bluray player.

I played this .mp4 and two .avi files at the default aspect and fullscreen, skipped forward several times and it didn't stutter or lag at all.





I compile all my programs from ports.


----------

