qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] Add support for depth 15 to qemu_default_pixelformat()
@ 2010-05-21  9:59 Gerd Hoffmann
  2010-06-01 18:28 ` Anthony Liguori
  0 siblings, 1 reply; 2+ messages in thread
From: Gerd Hoffmann @ 2010-05-21  9:59 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gerd Hoffmann

Makes qemu_default_pixelformat(15) return pixelformat filled for 15 bit
color depth (16 bpp, 5 bits for red,green,blue each, 1 bit unused).

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 console.c |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/console.c b/console.c
index 7070b1b..c91e2bb 100644
--- a/console.c
+++ b/console.c
@@ -1621,6 +1621,22 @@ PixelFormat qemu_default_pixelformat(int bpp)
     pf.depth = bpp == 32 ? 24 : bpp;
 
     switch (bpp) {
+        case 15:
+            pf.bits_per_pixel = 16;
+            pf.bytes_per_pixel = 2;
+            pf.rmask = 0x00007c00;
+            pf.gmask = 0x000003E0;
+            pf.bmask = 0x0000001F;
+            pf.rmax = 31;
+            pf.gmax = 31;
+            pf.bmax = 31;
+            pf.rshift = 10;
+            pf.gshift = 5;
+            pf.bshift = 0;
+            pf.rbits = 5;
+            pf.gbits = 5;
+            pf.bbits = 5;
+            break;
         case 16:
             pf.rmask = 0x0000F800;
             pf.gmask = 0x000007E0;
-- 
1.6.6.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH] Add support for depth 15 to qemu_default_pixelformat()
  2010-05-21  9:59 [Qemu-devel] [PATCH] Add support for depth 15 to qemu_default_pixelformat() Gerd Hoffmann
@ 2010-06-01 18:28 ` Anthony Liguori
  0 siblings, 0 replies; 2+ messages in thread
From: Anthony Liguori @ 2010-06-01 18:28 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: qemu-devel

On 05/21/2010 04:59 AM, Gerd Hoffmann wrote:
> Makes qemu_default_pixelformat(15) return pixelformat filled for 15 bit
> color depth (16 bpp, 5 bits for red,green,blue each, 1 bit unused).
>
> Signed-off-by: Gerd Hoffmann<kraxel@redhat.com>
>    

Applied.  Thanks.

Regards,

Anthony Liguori
> ---
>   console.c |   16 ++++++++++++++++
>   1 files changed, 16 insertions(+), 0 deletions(-)
>
> diff --git a/console.c b/console.c
> index 7070b1b..c91e2bb 100644
> --- a/console.c
> +++ b/console.c
> @@ -1621,6 +1621,22 @@ PixelFormat qemu_default_pixelformat(int bpp)
>       pf.depth = bpp == 32 ? 24 : bpp;
>
>       switch (bpp) {
> +        case 15:
> +            pf.bits_per_pixel = 16;
> +            pf.bytes_per_pixel = 2;
> +            pf.rmask = 0x00007c00;
> +            pf.gmask = 0x000003E0;
> +            pf.bmask = 0x0000001F;
> +            pf.rmax = 31;
> +            pf.gmax = 31;
> +            pf.bmax = 31;
> +            pf.rshift = 10;
> +            pf.gshift = 5;
> +            pf.bshift = 0;
> +            pf.rbits = 5;
> +            pf.gbits = 5;
> +            pf.bbits = 5;
> +            break;
>           case 16:
>               pf.rmask = 0x0000F800;
>               pf.gmask = 0x000007E0;
>    

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-06-01 18:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-21  9:59 [Qemu-devel] [PATCH] Add support for depth 15 to qemu_default_pixelformat() Gerd Hoffmann
2010-06-01 18:28 ` Anthony Liguori

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).