Bug 27900 - Vlc doesn't display the video for some .mpg files
Summary: Vlc doesn't display the video for some .mpg files
Status: RESOLVED INVALID
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 8
Hardware: x86_64 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Mageia Bug Squad
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-22 14:53 CET by Philippe Didier
Modified: 2020-12-27 17:43 CET (History)
2 users (show)

See Also:
Source RPM: vlc-3.0.11.1-6
CVE:
Status comment: Fix: Setting VLC video output module to XCB in some cases for nVidia Graphic cards


Attachments

Description Philippe Didier 2020-12-22 14:53:32 CET
Hi all 
I am very satisfied with the last beta2 Plasma Live DVD quite perfect
I tested it a lot, trying to find any problem and found only details :

Description of problem:

Vlc doesn't display the video for some .mpg files 
Version-Release number : 3.0.11.1-6 tainted (tested with a beta2 plasma Live CD)

Very surprising : Vlc can read every kind of files (mkv, flv, avi, mp4, ts, webm etc...)
but I get some problems with some mpg files (with the same codec)
Some are well displayed
But for some of them there's a black screen
The workaround is to set the output module from automatic to XCB and then it's OK

This doesn't happen with VLC in Mageia 7 with the same mpg files

I can't provide the mpg files that are problematic because they are very huge (300 Mbytes !)

Perhaps must I upload one of them on a kind of dropbox to test ? 
You just have to ask for it...

PS in the beginning of Mageia 7 Vlc had problems with Mkv videos but it was resolved when Mageia provided an update
Comment 1 Rolf Pedersen 2020-12-22 15:32:23 CET
Is this possibly related?:
https://bugs.mageia.org/show_bug.cgi?id=27377

CC: (none) => rolfpedersen

Comment 2 Aurelien Oudelet 2020-12-22 18:07:58 CET
Hi, thanks reporting this.

I do thing a dup of Bug 27377 but, @reporter, can you try this:

$ vlc --avcodec-hw none NAME_OF_PROBLEMATIC_FILE


Can you also provide the output of:
$ inxi -G

CC: (none) => ouaurelien

Comment 3 Philippe Didier 2020-12-23 12:38:52 CET
Hi
I don't think it's a dup of Bug 27377 because VLC displays every mp4 avi flv etc files
The black screen happens only on some mpg (not all) and there's an easy workaround for these problematic files

I'm gonna try what you suggest and give you the results
Comment 4 Philippe Didier 2020-12-23 13:39:41 CET
Hi Aurelien

Firstly I forgot to give a description of the hardware :
CPU  :AMD Athlon 4200
Graphic card : NVidia GeForce 210 (GT 218)
2 Western Digital internal hdd
1 USB hdd
1 FireWire HDD
First display : DVI Philips 201B
second Display : Sony TV (HDMI)
Soundcard : SoundBlaster Live !
Wacom Intuos3
Webcam : Quickcam 

I tried 
$ vlc --avcodec-hw none NAME_OF_PROBLEMATIC_FILE
and it works well

here's the result of inxi -G
Graphics:
  Device-1: NVIDIA GT218 [GeForce 210] driver: nvidia 
  v: 340.108 
  Display: x11 server: Mageia X.org 1.20.10 
  driver: nvidia,v4l resolution: 1: 1280x960 
  2: 1280x720~60Hz 
  OpenGL: renderer: GeForce 210/PCIe/SSE2 
  v: 3.3.0 NVIDIA 340.108 

NB
I found an other workaround without modifying VLC settings :
In Plasma settings, compositing, I choose OpenGL 3.1 instead of openGL 2.0
and there's no more problem for displaying the video !!!

It seems to be rather a plasma problem than a VLC problem !
Comment 5 Aurelien Oudelet 2020-12-23 14:20:10 CET
(In reply to Philippe Didier from comment #4)
> Hi Aurelien
> 
> Firstly I forgot to give a description of the hardware :
> CPU  :AMD Athlon 4200
> Graphic card : NVidia GeForce 210 (GT 218)

> I tried 
> $ vlc --avcodec-hw none NAME_OF_PROBLEMATIC_FILE
> and it works well

So, disabling hardware-based video decode help here.
But:

> here's the result of inxi -G
> Graphics:
>   Device-1: NVIDIA GT218 [GeForce 210] driver: nvidia 
>   v: 340.108 
>   Display: x11 server: Mageia X.org 1.20.10 
>   driver: nvidia,v4l resolution: 1: 1280x960 
>   2: 1280x720~60Hz 
>   OpenGL: renderer: GeForce 210/PCIe/SSE2 
>   v: 3.3.0 NVIDIA 340.108 
> 
> NB
> I found an other workaround without modifying VLC settings :
> In Plasma settings, compositing, I choose OpenGL 3.1 instead of openGL 2.0
> and there's no more problem for displaying the video !!!
> 
> It seems to be rather a plasma problem than a VLC problem !

No, the culprit is a combination of all elements:
Plasma rendering at OpenGL 2.0 + nvidia Graphic Card + nvidia nonfree drivers.

But, this is the default UPSTREAM developers recommend. They already know that they should support more recent OpenGL API, 

The best setting should be:
1) driver for NVIDIA cards
2) use of OpenGL 3.1 under Plasma, in Compositor Rendering.

That's why testing Plasma under a VM (virtualbox masks the issue).
On real hardware, the compositor (KWin) must use latest API to render well.

This is a candidate to RELEASE_NOTES_8

Keywords: (none) => FOR_RELEASENOTES8

Aurelien Oudelet 2020-12-23 14:21:16 CET

Status comment: (none) => fixed by setting compositor to use OpenGL 3.1 in Compositor Settings

Comment 6 Philippe Didier 2020-12-23 14:30:42 CET
Sorry : wrong diagnostic !!
I wrote this :
"I found an other workaround without modifying VLC settings :
In Plasma settings, compositing, I choose OpenGL 3.1 instead of openGL 2.0
and there's no more problem for displaying the video !!!

It seems to be rather a plasma problem than a VLC problem !"

And it's wrong!!!!

When I modified the plasma settings of OpenGL, I forgot to modify back the VLC settings of the output module to automatic, I had let it to XCB...

I tried again VLC turned to automatic output module and plasma to OpenGL 3.1 and there's no display of the video for the problematic mpg files..

So it'not a Plasma problem but only VLC that seems not to accept hardware acceleration for some mpg files on old nVidia graphic cards

The workaround (modify the video output module of VLC from automatic to XCB) may be added in the Mageia 8 notes in case of this problem occurs... unless a solution is found

Status comment: fixed by setting compositor to use OpenGL 3.1 in Compositor Settings => (none)
Keywords: FOR_RELEASENOTES8 => (none)

Comment 7 Philippe Didier 2020-12-23 14:35:40 CET
Sorry for the wrong diagnostic and the wrong solution about Plasma
You may change 
Status comment
fixed by setting VLC video output module to XCB in some cases for nVidia Graphic cards
Comment 8 Philippe Didier 2020-12-23 14:44:15 CET
PS
I didn't test in VM but with the Live CD used as a LiveCD
Adding the tainted VLC tainted rpms and plugins

Using OpenGL 3.1 or 2.0 doesn't change anything in fact (a contrario what I wrote in comment 4)
the workaround is only in VLC video output module set to XCB
Comment 9 Aurelien Oudelet 2020-12-27 17:43:18 CET
I do think it is not a packaging error.

We have switched to glvnd (vendor neutral dispatcher for openGL, VDPAU is for hardware-based codec/decode support. It should use nvidia on nvidia hardware with nonfree drivers only. If using AMD device, it should use amdgpu. On Intel, it uses Intel GPU to decode, through normal drivers.

All seems to run well on my side, even with some AVCHD files from a old camcorder.

Also, I suggest to try on a real hardware and an installed version on a harddrive, not a liveCD one.
Don't forget to add tainted repository.

But, I must point out that your hardware become obsolete:
Device-1: NVIDIA GT218 [GeForce 210] driver: nvidia 
>   v: 340.108 
>   Display: x11 server: Mageia X.org 1.20.10 
>   driver: nvidia,v4l resolution: 1: 1280x960 
>   2: 1280x720~60Hz 
>   OpenGL: renderer: GeForce 210/PCIe/SSE2 
>   v: 3.3.0 NVIDIA 340.108 

We provide fixes in order to have it compile on latest Kernel but the only NVIDIA-supported drivers for Hardware decoding with latest kernel is 455.55 series and onwards.
The 340 serie is EOL.

This association of hardware + drivers + software can produce bad user experience. In this case, for these particular file, the automatic choice made by VLC is a bad solution. You, as user, must select XCB as render for the video which is beyond the scope of packaging a RPM.

It is sad that nvidia only care about latest hardware...


So, closing this, sorry, but adding a comment in status.

Status comment: (none) => Fix: Setting VLC video output module to XCB in some cases for nVidia Graphic cards
Status: NEW => RESOLVED
Resolution: (none) => INVALID


Note You need to log in before you can comment on or make changes to this bug.