Did you notice I said "web videos"? I'm talking about web browsers. I'm aware that mpv and vlc and others can use video acceleration okay, but they don't have complicated browser UI problems to solve.
Yes, I did notice that. There is nothing preventing a web browser from using the same methods and libraries.
> they don't have complicated browser UI problems
While not as complex, they do have a UI that overlays the video. However, the complexity of the UI doesn't affect video acceleration. Using libvdpau as an example, the X11 client provides[1] a separate child window[2]:
>> VDPAU expects to own the entire drawable [...] it is recommended that applications create a dedicated window for the presentation queue target, as a child (grand-child, ...) of their top-level application window.
The video playback happens in its own sandbox. Other non-video part of the UI should use their own child windows, isolated and independent of the video playback. The UI's child windows can be as complex as necessary, including overlaying the video[1]:
>> Applications may also create child-windows of the presentation queue target, which will cover any presented video in the normal fashion. VDPAU implementations will not manipulate such child windows in any fashion.
The child windows can even be alpha blended[3] with the video or other UI layers.
Reading back video data (to implement features like CanvasRenderingContext2D.getImageData()) is easy: read the video window like you would read any X11 Drawable.
What, exactly, was the "complicated UI problem" that supposedly wasn't possible to implement in X11?
If it is all so straightforward, what is your explanation for no web browser on Linux officially support video acceleration? Not Firefox, not Chrome, not Gnome Web, not Falkon, nothing. Despite video players just doing it. Just possibly, could it mean that it's actually not that straightforward in a browser?
By the way, if you would read the actual base of the story here, you would know why it took Firefox's Wayland refactoring to actually pull this off [1].