Vlc only sometimes shows with video on 22.10 and Nvidia drivers

Typically, the first video played will work, but subsequent ones show a black screen although the sound continues to work. Restarting vlc resets the problem.. usually.

| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-==============-============-============-=================================
ii vlc 3.0.17.4-5 amd64 multimedia player and streamer

ii nvidia-compute-utils-510 510.85.02-0ubuntu2 amd64 NVIDIA compute utilities
ii nvidia-dkms-510 510.85.02-0ubuntu2 amd64 NVIDIA DKMS package
ii nvidia-driver-510 510.85.02-0ubuntu2 amd64 NVIDIA driver metapackage
ii nvidia-kernel-common-510 510.85.02-0ubuntu2 amd64 Shared files used with the kernel module
ii nvidia-kernel-source-510 510.85.02-0ubuntu2 amd64 NVIDIA kernel source package
ii nvidia-prime 0.8.17.1 all Tools to enable NVIDIA's Prime
ii nvidia-settings 510.47.03-0ubuntu1 amd64 Tool for configuring the NVIDIA graphics driver
ii nvidia-utils-510 510.85.02-0ubuntu2 amd64 NVIDIA driver support binaries

I have also tried installing the 515 drivers, but the problem remains.

Bug #1994082 “vlc will only sometimes show video with nvidia dri...” : Bugs : nvidia-graphics-drivers-515 package : Ubuntu has a couple of .xsession-errors logfiles of it happening.

Also happens with the nouveau video drivers.

Good to know, that makes VLC the main suspect :slight_smile:

Maybe this will help:
You could try to disable hardware acceleration in VLC

From VLC menu:
extra -> preferences -> input/codecs
and switch 'hardware accellerated decoding' to off
(don't forget to save the setting)

If VLC keeps on working now, so much the better, keep it that way.
(you can, ofcourse, file a bug against VLC)

About the hardware accelerated decoding on VLC:
Contrary to Hardware decoding in MPV, it is not very efficient.
In other words: it does not offer much speed advantage in VLC.
VLC copies the decoded frames back to memory for post processing done by the CPU
therefore minimizing the speed advantage that hardware decoding can offer.
Also, the videoformats that it can decode in hardware are pretty limited.

1 Like

Disabling hardware acceleration doesn't help for me - still the same 'only show one video' issue.

Happens for me too, and I don't have Nvidia so I think the culprit is Vlc itself. Disabling hardware accelerated decoding and explicitly setting output-method also does nothing.

To be clear, one and the same video-file sometimes plays normally, and sometimes has only the sound working while the video-output remains a black rectangle. I've not been able to find any clear pattern to when it works and when it doesn't. Subsequent identical openings of the same file sometimes works, and sometimes doesn't.

1 Like

Welcome @Eivind_Kjorstad to the community!

1 Like