Commit c7bd7bec8cc34489be3048afccaeea91169ac15f

Authored by aliguori
1 parent bd54b863

Fix SDL problems with BGR displays (Avi Kivity)

revert qemu's sdl.c rev 1.40

this fixes problems with bgr displays.

Signed-off-by: Avi Kivity <avi@qumranet.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4925 c046a42c-6fe2-441c-8c8c-71466251a162
Showing 1 changed file with 1 additions and 1 deletions
... ... @@ -89,7 +89,7 @@ static void sdl_resize(DisplayState *ds, int w, int h)
89 89 ds->data = screen->pixels;
90 90 ds->linesize = screen->pitch;
91 91 ds->depth = screen->format->BitsPerPixel;
92   - if (screen->format->Bshift > screen->format->Rshift) {
  92 + if (ds->depth == 32 && screen->format->Rshift == 0) {
93 93 ds->bgr = 1;
94 94 } else {
95 95 ds->bgr = 0;
... ...