[vlc-devel] commit: Ugly hack to prevent qt4-x11 from using alpha channel ( Rémi Denis-Courmont )

git version control git at videolan.org
Sun Nov 15 16:10:01 CET 2009


vlc | branch: 1.0-bugfix | Rémi Denis-Courmont <remi at remlab.net> | Sun Nov 15 17:03:17 2009 +0200| [c0ec5be56e71c273eef4faea8d927eeb3cbc7ec5] | committer: Rémi Denis-Courmont 

Ugly hack to prevent qt4-x11 from using alpha channel

This breaks our current Xlib XVideo and plain X11 outputs.
Qt4 would create an ARGB window for our embedded video. Then, the
Xlib plugins would raise BadMatch errors and VLC aborts. Starting
cairo-dock is an easy way to trigger this problem.
(With XCB plugins, we fail safe to OpenGL/GLX instead of crashing.)

We should instead handle ARGB visuals properly. But that would involve
more efforts, and would only enable plain X11, not XVideo anyway.

This should work around LP#416294.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c0ec5be56e71c273eef4faea8d927eeb3cbc7ec5
---

 modules/gui/qt4/qt4.cpp |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/modules/gui/qt4/qt4.cpp b/modules/gui/qt4/qt4.cpp
index 49e7732..d005434 100644
--- a/modules/gui/qt4/qt4.cpp
+++ b/modules/gui/qt4/qt4.cpp
@@ -282,6 +282,7 @@ static int Open( vlc_object_t *p_this )
         return VLC_EGENERIC;
     }
     XCloseDisplay( p_display );
+    putenv( "XLIB_SKIP_ARGB_VISUALS=1" );
 #endif
 
     /* Allocations of p_sys */




More information about the vlc-devel mailing list