[vlc-devel] Qt5 for X11

Rémi Denis-Courmont remi at remlab.net
Fri Apr 4 16:16:12 CEST 2014


On Fri, 04 Apr 2014 15:51:23 +0200, Francois Cartegnie <fcvlcdev at free.fr>
wrote:
> Anyone tried to fix X11 VideoWidget ?

That is not even the question. The video widget should no longer depend on
the windowing system, otherwise it will never function. WindowOpen() needs
to perform a run-time check instead.

> As Q_WS_X11 is no longer defined, neither QX11Info, the widget window id
> is no longer grabbed.

That is actually correct. There are no warranties anymore that the
back-end is Xlib, not even hat the window is an X11 window. I am not even
sure that there is an Xlib back-end at all anymore, since XCB is now the
default.

> As Qt now abstracts an XCB backend, it only provides a "native"
> interface to access native resources.
> 
> I've tried to map our xlib calls back:
> 
> - On the XSync part, something seems wrong with the returned display,
> and then segfaults.

Obviously XSync() does not really work with XCB, and does not work at all
with other windowing systems. Ideally, Qt5 will do the right thing out of
the box, or will provide an abstracted synchronization function. Otherwise
new code will be needed.

> - On the window events, unsure what's wrong, either a different Id or a
> QApplication still registered for events. (explaints the
> nativeeventfilter interface).

That hack is only useful for mouse clicks and should be removed completely
to support EGL anyway. Thus updating that snippet for Qt5 seems rather
vain. To get rid of this hack, some changes are needed to the vout window
core to avoid this, so I will not fix it until after VLC 2.2 comes out.

-- 
Rémi Denis-Courmont
Sent from my collocated server



More information about the vlc-devel mailing list