# HG changeset patch # User pacman # Date 1140148173 0 # Node ID 479b64764d9eac236e385798a88ba7c862f007ab # Parent b849a99cdc3c2e107396683da096e97497304694 Fix colormap save/restore for directcolor fb devices diff -r b849a99cdc3c -r 479b64764d9e libvo/vo_fbdev.c --- a/libvo/vo_fbdev.c Fri Feb 17 01:57:41 2006 +0000 +++ b/libvo/vo_fbdev.c Fri Feb 17 03:49:33 2006 +0000 @@ -549,7 +549,8 @@ static struct fb_fix_screeninfo fb_finfo; static struct fb_var_screeninfo fb_orig_vinfo; static struct fb_var_screeninfo fb_vinfo; -static struct fb_cmap fb_oldcmap; +static unsigned short fb_ored[256], fb_ogreen[256], fb_oblue[256]; +static struct fb_cmap fb_oldcmap = { 0, 256, fb_ored, fb_ogreen, fb_oblue }; static int fb_cmap_changed = 0; static int fb_pixel_size; // 32: 4 24: 3 16: 2 15: 2 static int fb_bpp; // 32: 32 24: 24 16: 16 15: 15 diff -r b849a99cdc3c -r 479b64764d9e libvo/vo_fbdev2.c --- a/libvo/vo_fbdev2.c Fri Feb 17 01:57:41 2006 +0000 +++ b/libvo/vo_fbdev2.c Fri Feb 17 03:49:33 2006 +0000 @@ -72,7 +72,8 @@ static struct fb_fix_screeninfo fb_finfo; // fixed info static struct fb_var_screeninfo fb_vinfo; // variable info static struct fb_var_screeninfo fb_orig_vinfo; // variable info to restore later -static struct fb_cmap fb_oldcmap; // cmap to restore later +static unsigned short fb_ored[256], fb_ogreen[256], fb_oblue[256]; +static struct fb_cmap fb_oldcmap = { 0, 256, fb_ored, fb_ogreen, fb_oblue }; static int fb_cmap_changed = 0; // to restore map static int fb_pixel_size; // 32: 4 24: 3 16: 2 15: 2 static int fb_bpp; // 32: 32 24: 24 16: 16 15: 15