程式語言 - Simple DirectMedia Layer (SDL) - v1.2 - 如何知道SDL是否設定成SDL_DOUBLEBUF



fb_set_par()可以透過計算fb_info->var.yres_virtual的大小(相較fb_info->var.yres)得知

(SDL 1.2.15)src/video/fbcon/SDL_fbvideo.c +1040

 if ( (vinfo.xres != width) || (vinfo.yres != height) ||
      (vinfo.bits_per_pixel != bpp) || (flags & SDL_DOUBLEBUF) ) {
   vinfo.activate = FB_ACTIVATE_NOW;
   vinfo.accel_flags = 0;
   vinfo.bits_per_pixel = bpp;
   vinfo.xres = width;
   vinfo.xres_virtual = width;
   vinfo.yres = height;
   if ( flags & SDL_DOUBLEBUF ) {
     vinfo.yres_virtual = height*2;
   } else {
     vinfo.yres_virtual = height;
   }