diff options
Diffstat (limited to 'recipes/ekiga/ekiga/rgb16.patch')
-rw-r--r-- | recipes/ekiga/ekiga/rgb16.patch | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/recipes/ekiga/ekiga/rgb16.patch b/recipes/ekiga/ekiga/rgb16.patch new file mode 100644 index 0000000000..b9c9ab284a --- /dev/null +++ b/recipes/ekiga/ekiga/rgb16.patch @@ -0,0 +1,51 @@ +From: Ying-Chun Liu (PaulLiu) <paulliu@debian.org> +Subject: Add RGB16 support +Last-Update: 2010-02-26 +Index: ekiga-3.2.6/lib/gui/xwindow.cpp +=================================================================== +--- ekiga-3.2.6.orig/lib/gui/xwindow.cpp 2010-02-26 07:53:47.000000000 -0500 ++++ ekiga-3.2.6/lib/gui/xwindow.cpp 2010-02-26 07:57:32.000000000 -0500 +@@ -82,6 +82,7 @@ + {"RGBA", 1, 0, LSBFirst, 0x000000FF, 0x0000FF00, 0x00FF0000}, //RGBA * + {"BGR32", 1, 4, MSBFirst, 0x0000FF00, 0x00FF0000, 0xFF000000}, //BGRA + {"BGRA", 1, 0, LSBFirst, 0x00FF0000, 0x0000FF00, 0x000000FF}, //BGRA * ++ {"RGB16", 16, 2, LSBFirst, 0x0000F800, 0x000007E0, 0x0000001F}, //RGB16 + {NULL, 0, 0, 0, 0, 0, 0} + }; + +@@ -1021,6 +1022,17 @@ + } + } + } ++ else if (xwattributes.depth == 16) { ++ _depth = 16; ++ if (!XMatchVisualInfo (_display, DefaultScreen (_display), _depth, TrueColor, &_XVInfo)) { ++ PTRACE(4, "X11\tCould not find visual with colordepth of " << _depth << " bits per pixel"); ++ _depth = 24; ++ if (!XMatchVisualInfo (_display, DefaultScreen (_display), _depth, TrueColor, &_XVInfo)) { ++ PTRACE(1, "X11\tCould neither find visual with colordepth of 16 bits per pixel nor with 24 bits per pixel"); ++ return false; ++ } ++ } ++ } + else { + _depth = 24; + if (!XMatchVisualInfo (_display, DefaultScreen (_display), _depth, TrueColor, &_XVInfo)) { +Index: ekiga-3.2.6/lib/pixops/pixops.c +=================================================================== +--- ekiga-3.2.6.orig/lib/pixops/pixops.c 2010-02-26 07:58:06.000000000 -0500 ++++ ekiga-3.2.6/lib/pixops/pixops.c 2010-02-26 07:59:22.000000000 -0500 +@@ -157,6 +157,13 @@ + INNER_LOOP(4, 4, p32=(guint32*)dest;*p32=*((guint32*)p)); + } + } ++ else if (src_channels == 2) ++ { ++ if (dest_channels == 2) ++ { ++ INNER_LOOP (2, 2, dest[0]=p[0];dest[1]=p[1]); ++ } ++ } + } + } + |