I have made some investigations, and I have almost found the bug.

* The X server has chosen a format with 24 bit depth and 24 bits_per_pixel, 
which seems
pretty unusual.

(source is qt/src/gui/image/qnativeimage.cpp)
* QNativeImage::format() returns either 16 or 32 bits, but never 24!
  -> This is the cause of the garbage in the display.

* QNativeImage::QNativeImage is called with the 32bit format, and allocates a 
Ximage (using XShmCreateImage) of the default (-> 24). 
* Result : QImage thinks we've 4 bytes per pixel, XImage 3 bytes per pixel and 
this is the source of the segfault.

I have tried hacking QNativeImage::format() to return
QImage::Format_RGB888, there is no more segfault, but the red and blue
channels are inverted.

Hope this helps.

-- 
You received this bug notification because you are a member of Kubuntu
Bugs, which is subscribed to qt4-x11 in Ubuntu.
https://bugs.launchpad.net/bugs/759803

Title:
  Unity-2d not working on KVM with xen and cirrus video devices

To manage notifications about this bug go to:
https://bugs.launchpad.net/unity-2d/+bug/759803/+subscriptions

-- 
kubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/kubuntu-bugs

Reply via email to