[Mplayer-cvslog] CVS: main/libvo vo_fbdev.c,1.10,1.11
Szabolcs Berecz
szabii at users.sourceforge.net
Sun Apr 8 01:05:16 CEST 2001
Update of /cvsroot/mplayer/main/libvo
In directory usw-pr-cvs1:/tmp/cvs-serv28595
Modified Files:
vo_fbdev.c
Log Message:
restore old cmap
Index: vo_fbdev.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_fbdev.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -r1.10 -r1.11
*** vo_fbdev.c 2001/04/07 22:03:18 1.10
--- vo_fbdev.c 2001/04/07 23:05:14 1.11
***************
*** 48,51 ****
--- 48,52 ----
static uint32_t fb_xres_virtual;
static uint32_t fb_yres_virtual;
+ static struct fb_cmap *oldcmap = NULL;
static int in_width;
***************
*** 246,249 ****
--- 247,255 ----
if (fb_fix_info.visual == FB_VISUAL_DIRECTCOLOR) {
printf("fb_init: creating cmap for directcolor\n");
+ if (ioctl(fb_dev_fd, FBIOGETCMAP, oldcmap)) {
+ printf("fb_init: can't get cmap: %s\n",
+ strerror(errno));
+ goto err_out_fd;
+ }
if (!(cmap = make_directcolor_cmap(&fb_var_info)))
goto err_out_fd;
***************
*** 455,458 ****
--- 461,469 ----
{
printf("vo_fbdev: uninit\n");
+ if (oldcmap) {
+ if (ioctl(fb_dev_fd, FBIOPUTCMAP, oldcmap))
+ printf("vo_fbdev: Can't restore original cmap\n");
+ oldcmap = NULL;
+ }
fb_var_info.xres_virtual = fb_xres_virtual;
fb_var_info.yres_virtual = fb_yres_virtual;
_______________________________________________
Mplayer-cvslog mailing list
Mplayer-cvslog at lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/mplayer-cvslog
More information about the MPlayer-cvslog
mailing list