-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
libmpv: Severe screen corruption when rendering video via mpv_render_context_render to virtual x-server #14577
Comments
There absolutely is. Set the "log-file" option via libmpv. |
I have added |
it's not |
Here is an mpv log file while the problem occurs.
|
Duplicate of #13998 |
Are you sure? I don't see |
I have tried adding correct-downscaling=no to the mpv configuration
Adding profile=fast produced no pictures at all |
I'm not sure what's going on here. I think we are looking at multiple different issues. For example the screenshot from #14577 (comment) shows corruption that happens with Intel when using gather. But indeed previous report was about Windows and gpu-next. Though the symptoms are the same. First broken commit c172a65 makes it clear we have some issue when downscaling, which is the same case as in the other issue.
Ok, so it seems to confirm that at least part of the problem is the same as the other one.
That's worrying, because in this mode, we really don't do much work.
Are you able to test with older mesa build? I'm curious if those issues are new or were there before. |
It would also be helpful to link the code in the application where mpv is integrated. |
In neumoDVB, this is the source file that handles libmpv callbacks Re the constraints: I am aware of those, although it is not always easy to understand The culprit then turned out to be illegal access from multiple If you are wondering about the convoluted construct with the thread_local variable Regarding the issue of this ticket, this is not relevant, as only one playback is running I found the limbmpv docoumentation you link to a bit misleading:
|
This is incorrect. Looking at neumompv.cc you seem to be doing this correctly. |
In any case it should be easy to reproduce this bug with one of the mpv examples. |
Yes, that is what I wrote: "it is libmpv that creates and controls the tread, not the api user."
That is the thread calling the user callback, so an mpv thread and not controlled by the user. Otherwise it will get really complicated, as the user code callback can
No, I did not claim that it mpv draws. The user callback draws, but it does that in a thread I can understand why libmpv would call from a seperate thread for each video playback, but it would be helpful to mention this in the documentation, along with a warning that openGL then requires using a separate GL context per thread (it did not require that in older versions).
Thanks for that confirmation. |
No. Why would you need that?
Yes. This is what you have to do and just how the sdl example I linked works.
No, this is the exact opposite of what I said.
Lines 31 to 40 in acc69e0
|
It seems I was confused by some older, dead code in neuomdvb. The rendering indeed |
mpv Information
Other Information
Linux version:
Fedora Linux
Kernel Version:
6.9.8-200.fc40.x86_64
GPU Model:
Intel Corporation AlderLake-S GT1
Mesa/GPU Driver Version:
mesa-libGLU-9.0.3-4.fc40.x86_64
mesa-libGLU-devel-9.0.3-4.fc40.x86_64
mesa-filesystem-24.1.2-8.fc40.x86_64
mesa-va-drivers-24.1.2-8.fc40.x86_64
mesa-libglapi-24.1.2-8.fc40.x86_64
mesa-dri-drivers-24.1.2-8.fc40.x86_64
mesa-libgbm-24.1.2-8.fc40.x86_64
mesa-libEGL-24.1.2-8.fc40.x86_64
mesa-libgbm-devel-24.1.2-8.fc40.x86_64
mesa-libGL-24.1.2-8.fc40.x86_64
mesa-libGL-devel-24.1.2-8.fc40.x86_64
mesa-libEGL-devel-24.1.2-8.fc40.x86_64
mesa-libOpenCL-24.1.2-8.fc40.x86_64
mesa-vulkan-drivers-24.1.2-8.fc40.x86_64
mesa-libxatracker-24.1.2-8.fc40.x86_64
mesa-libOSMesa-24.1.2-8.fc40.x86_64
Window Manager and Version:
mate marco
Source mpv:
from git
Introduced in version:
c172a65
not possible to reproduce in 3e612c0
Reproduction Steps
The problem can be reproduced using xpra
-start xpra in seamless mode, e.g., starting a terminal which runs
on a remote computer. Under the hood this starts an Xserver
with Xdummy or Xvfb. The problem occurs with both.
-in this terminal start a program that uses mpv-lib
For instance https://github.com/v0idv0id/MPVideoCube.git
Or (more difficult to compile:
https://github.com/deeptho/neumodvb
Sometimes the video displayed in the programs
looks ok, but sometimes video is heavily corrupted.
Investigation shows
Expected Behavior
Non-corrupted video
Actual Behavior
Corrupted video.
Additional info:
a difference in default interpolation code, but that may just "trigger" the problem, rather than being the cause.
Please see the sreenshots here: Xpra-org/xpra#4300
I cannot attach log files, as there are none in this use case. Or is it possible to start one
in libmpv?
Log File
xxx.log
Sample Files
I carefully read all instruction and confirm that I did the following:
--log-file=output.txt
.The text was updated successfully, but these errors were encountered: