Bug 37629 - Transparency issue when using remote X server with xdmcp or LTSP
Transparency issue when using remote X server with xdmcp or LTSP
Status: RESOLVED DUPLICATE of bug 40926
Product: xorg
Classification: Unclassified
Component: Driver/intel
7.6 (2010.12)
x86 (IA32) Linux (All)
: medium major
Assigned To: Chris Wilson
Xorg Project Team
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-05-26 06:51 UTC by Marc Gariépy
Modified: 2011-11-03 11:27 UTC (History)
2 users (show)

See Also:


Attachments
only GTK programs seem to be affected (531.42 KB, image/png)
2011-08-23 01:23 UTC, Martin
no flags Details
seems to work for me, yet not the solution (872 bytes, patch)
2011-08-29 23:59 UTC, Martin
no flags Details | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Marc Gariépy 2011-05-26 06:51:33 UTC
The transparency of icons doesn't work on those card with driver version 2.14 and 2.15.

When using v2.12 the problem isn't present.

there is more information here: https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/785280

I have the same behaviour with both cards:

00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (primary) [8086:2a02] (rev 0c)
00:02.1 Display controller [0380]: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (secondary) [8086:2a03] (rev 0c)

00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller [8086:2a42] (rev 09)
00:02.1 Display controller [0380]: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller [8086:2a43] (rev 09)

This one doesn't have the issue:

00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 945GME Express Integrated Graphics Controller [8086:27ae] (rev 03)
00:02.1 Display controller [0380]: Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller [8086:27a6] (rev 03)
Comment 1 Jonathan Carter 2011-06-09 12:03:27 UTC
I did a git bisect between the last known good version and the known bad version.

I don't currently have the time to compile the driver and assosicate X stack, etc with it, so I just ran through the suggestions and looked if anything standed out.

So far this seems like it could be a culprit:
http://cgit.freedesktop.org/xorg/driver/xf86-video-intel/commit/?id=4b7142baa0b3bf6f38843d06aadc579d8624cefc

I think I might just try to undo that with the 2.14 driver in Ubuntu Natty. That way I could test without having to rebuild everything. Any comments or suggestions will be appreciated!
Comment 2 Martin 2011-08-23 01:23:57 UTC
Created attachment 50474 [details]
only GTK programs seem to be affected
Comment 3 Martin 2011-08-23 01:36:38 UTC
This problem persists up to today's git version. All filed bugs (Gentoo, Launchpad, this one) attrtibute this to XDMCP or LTSP. My tests show, that the problem is in all versions starting from 2.13.902 and focuses around the GTK when shared memory (MIT-SHM) is unavailable. With the addtion of
<<< EOpaste
Section "Extensions"
    Option "MIT-SHM" "Disable"
EndSection
EOpaste
to the xorg.conf the transparency bug even occurs for GTK applications run locally and not on a remote machine.

I upgraded this bug to be major as it hampers all remote usage of GTK2-based programs, also the ones connected using ssh -X.
(I experience stability and "quality of experience" issues with versions below 2.14.90X of this driver, blocking deployment of our new infrastructure, hence my interest in this driver.)

I virtually went half-way through all combinations of (xserver{1.7,1.9,1.10) x (Mesa{7.10,7.11}) x (this driver all versions between 2.13.901 and HEAD and some intermediary git versions) x (kernel {2.6.37,2.6.38,3.0.3}) x (on the remote machine Gtk{2.20,2.22,2.24}).

The posts in the Launchpad bug (https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/785280) indicate this is a bug going through all fairly recent versions of X. I can confirm that this bug also occurs with versions 1.9 and 1.10 of the Xserver, yet I did most of my testing around Debian squeeze which comes with Xserver 1.7. Currently my software versions are the Intel 2011Q3 graphics package, while I'm still on Debian squeeze:
Kernel: Linux 3.0
3D driver: mesa 7.11
2D driver: xf86-video-intel 2.16.0
Libdrm: libdrm-2.4.26
Libva: libva-1.0.14
(Xserver: 1.7.7-13)

(2.14.902 and 2.15.901 won't compile in this environment.) 2.13.901 is the most recent version of this driver without the transparency problem. Not even disabling MIT-SHM will make it show the broken behaviour. It's always been like that, no matter what versions of xserver, mesa libdrm and GTK I used otherwise. The changes between 2.13.901 and 2.13.902 are too large and complex for me to identify the problem. As all versions >= 2.13.902 show this behaviour even when I exchange every other piece of software around it I must conclude this is a bug in this driver introduced with version 2.13.902.

I posted a screenshot earlier, illustrating the problem a litte more. It shows the GIMP and dia, both GTK programms with odd black areas where icons should be transparent. There are also dolphin and nautilus displaying previews of the same folder of icons. While dolphin displays the icons as expected, nautilus renders black where transparency should be. Nautilus also has broken icon-rendering. Note that the KDE window manager hasn't any problems rendering nautilus at reduced opacity overlapping serveral windows and other preview icons. This screenshot was taken with all programms running on a remote machine.
Comment 4 Martin 2011-08-23 14:41:56 UTC
I discovered git bisect ...
f3a47d7f235d18e4529e3898a48673c7c3cbd489 is the first bad commit
commit f3a47d7f235d18e4529e3898a48673c7c3cbd489
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Mon Dec 6 14:11:05 2010 +0000

    snb: Cache pixmap binding locations

    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

:040000 040000 4a1eb83e6831bceb66e6f6641d2314785abda5c6 6cb1c7448c1f9513a4f49951a08d554d5ee60faa M      src

Hope that helps.
Comment 5 Martin 2011-08-29 23:59:37 UTC
Created attachment 50675 [details] [review]
seems to work for me, yet not the solution

At https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/785280 Marc showed the exact little patch creating the problem. It's a case distinction in i965_render.c <code>if (is_dst)</code> where is_dst is of type Bool and is passed to functions as an argument in i965_bind_surfaces().

The attached is a patch against the 2.16.0 tag which adds <code>is_dst = 1;</code> as the first line of each relevant function, hence disabling the distinction. I suppose this disables the caching of pixmap binding locations and I hope it only disables the caching of pixmap binding locations.

I have been using this patched version of 2.16.0 for about 6 hours and I haven't noticed any side effects, yet. 

While the patch cannot be applied to HEAD, the method of adding <code>is_dst = 1;</code> to the appropriate functions in i965_render.c also worked here to get a driver without transparency problems.
Comment 6 Shlomi Fish 2011-09-17 04:03:45 UTC
I seem to have reported this bug again here:

https://bugs.freedesktop.org/show_bug.cgi?id=40926

Can this bug be fixed soon, please?

Regards,

-- Shlomi Fish
Comment 7 Marc Gariépy 2011-11-03 11:27:40 UTC

*** This bug has been marked as a duplicate of bug 40926 ***