Page 1 of 1

Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 2:07 pm
by theitercept
I'm using MX 18.3 on dell laptop with i5, 8gb ram. I'm unable to play any videos on my VLC media player. I'm able to play audios of the corresponding video. But no matter what kinda video i try to play I'm unable to do so. Could someone guide a noob like me in this matter.

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 2:30 pm
by JBoman
For starters try right click on the speaker icon on desktop and open the mixer and see if sound is muted or sliders need adjusted. :needcoffee:

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 3:01 pm
by theitercept
JBoman wrote: Sat Sep 07, 2019 2:30 pm For starters try right click on the speaker icon on desktop and open the mixer and see if sound is muted or sliders need adjusted. :needcoffee:
The problem isn't with sound but with video. I am unable to play videos.

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 3:05 pm
by Eadwine Rose
Can you start vlc in the terminal and then try to play the file? Might give some interesting output.

Re: Unable to play video in VLC media player  [Solved]

Posted: Sat Sep 07, 2019 3:14 pm
by Stevo
Often this is because of a problem "newer" library that was installed from the deb-multimedia repository. Have you ever added that repo? Plus the terminal output is always a great idea.

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 4:06 pm
by theitercept
Eadwine Rose wrote: Sat Sep 07, 2019 3:05 pm Can you start vlc in the terminal and then try to play the file? Might give some interesting output.
Tried it that way as you said. I'm getting something like [h264 @ 0x7f7450c4fd80] Failed to end picture decode issue: 6 (invalid VAsurface ID)
hardware accelerator failed to decode picture

I'm getting something similar error in a continuous manner on opening in terminal.

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 4:49 pm
by JBoman
Ok, maybe try Mx tools Mx codecs installer and see if missing codecs may be the problem. :needcoffee:

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 4:58 pm
by towwire
I can confirm that vlc will not show the video but does play the sound. Does not matter if I pick the file from the GUI or use the terminal. Here is the terminal errors:

Code: Select all

VLC media player 3.0.8 Vetinari (revision 3.0.8-0-gf350b6b5a7)
[0000559693de81a0] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface.
libva info: VA-API version 1.4.0
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/radeonsi_drv_video.so
libva info: Found init function __vaDriverInit_1_4
libva info: va_openDriver() returns 0
[00007f9bf00029f0] glconv_vaapi_x11 gl error: vaDeriveImage: invalid VASurfaceID
[00007f9c14045cc0] main video output error: video output creation failed
[00007f9c25590ca0] main decoder error: failed to create video output
[00007f9c25590ca0] avcodec decoder: Using G3DVL VDPAU Driver Shared Library version 1.0 for hardware decoding
The same video plays just fine in SMPlayer. Here is what it shows:

Code: Select all

Resolution: 1280 x 720
Aspect ratio: 1.7778
Format: H264
Bitrate: 815 kbps
Frames per second: 23.976
Selected codec: ffh264

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 5:13 pm
by Stevo
Your VLC's not built against the same version of Mesa, libva, and/or ffmpeg that you have installed. Va-api hardware accelerated video is pretty fragile in that way. The Debian VLC 3.0.8's va-api won't work on MX, for example. I build our main repo's VLC against the newer versions of those libraries in MX main, and then another version of VLC for the test repo against the newer versions of those in testing. So it boils down to the versions of those libraries and the build of VLC you have. If you upgraded one part of those libraries from the test repo and not the others, that can break it.

The quick and dirty fix is to disable the hardware acceleration in VLC's Tools--Preferences--Input/Codecs, and then restart VLC. A more satisfying fix is to get the acceleration to work.

Re: Unable to play video in VLC media player

Posted: Sat Sep 07, 2019 5:25 pm
by towwire
My files came from testrepo.

Code: Select all

2019-08-23  08:20:54  upgrade  vlc-bin                              amd64  3.0.8-2mx17+1                   3.0.8-2mx17+2
2019-08-23  08:20:54  upgrade  libvlc-bin                           amd64  3.0.8-2mx17+1                   3.0.8-2mx17+2
2019-08-23  08:20:54  upgrade  libvlc5                              amd64  3.0.8-2mx17+1                   3.0.8-2mx17+2
So what others do I need to check??

Re: Unable to play video in VLC media player

Posted: Sun Sep 08, 2019 1:47 am
by theitercept
Stevo wrote: Sat Sep 07, 2019 5:13 pm Your VLC's not built against the same version of Mesa, libva, and/or ffmpeg that you have installed. Va-api hardware accelerated video is pretty fragile in that way. The Debian VLC 3.0.8's va-api won't work on MX, for example. I build our main repo's VLC against the newer versions of those libraries in MX main, and then another version of VLC for the test repo against the newer versions of those in testing. So it boils down to the versions of those libraries and the build of VLC you have. If you upgraded one part of those libraries from the test repo and not the others, that can break it.

The quick and dirty fix is to disable the hardware acceleration in VLC's Tools--Preferences--Input/Codecs, and then restart VLC. A more satisfying fix is to get the acceleration to work.
Disabling hardware acceleration worked for me. I would like to know what are the things i should uninstall from test repo for vlc to work properly.

Re: Unable to play video in VLC media player

Posted: Sun Sep 08, 2019 2:08 am
by JayM
Can you run Quick System Info then just right-click/paste in a reply. No need to copy/paste, Quick System Info already copies it for you and pre-formats it for posting in the forum. Having information about your computer would be handy for the rest of us when making suggestions. Thanks.

Re: Unable to play video in VLC media player

Posted: Mon Sep 09, 2019 10:47 am
by truongtfg
Recently my laptop and PC also have this issue, the sound is fine, but the video is black. What I did to fix it without disabling hardware acceleration was changing the Output option in Tools/Preferences/Videos from 'Automactic' to 'Xvideo output (XCB)', then reopen the file.

Edit, Actually changing the output to 'Xvideo output (XCB)' seems to disable hardware acceleration. Instead, I have tried changing the Hardware-accelerated decoding in Tools/Preferences/Videos/[Input/Codecs] from Automatic or VDPAU to VA-API video decoder, and it also works. Apparently, VLC chooses VDPAU by default.
On second thought, I read that VA-API is used by Intel graphic card while VDPAU is for NVIDIA/AMD cards. On my PC with a RX 470, does it mean that hardware acceleration is disabled when I switch to VA-API?

BTW, my Laptop uses Intel integrated card. And Mesa driver version is 18.3.6-2.

Re: Unable to play video in VLC media player

Posted: Mon Sep 09, 2019 1:41 pm
by Stevo
If you want to use the VLC from the test repo with va-api hardware acceleration, then you should also upgrade ffmpeg from the test repo to the current 4.1.4. I think that will bring in Mesa 18.3.6 from the test repo, since I built ffmpeg 4.1.4 and then the test repo VLC against it.

I do know va-api works for me with the test repo VLC, ffmpeg, and Mesa libraries. You can install vainfo from the test repo and run it to make sure you have a working va-api, but remember it's not backwards-compatible, so the Debian or our main repo VLC's hardware acceleration won't work with the test repo's version.