README.PicoGUI
author Patrice Mandin <patmandin@gmail.com>
Thu, 19 Jan 2006 21:28:52 +0000
changeset 1257 448a9a64537b
parent 433 706de3956894
permissions -rw-r--r--
[PATCH] SDL_GetVideoMode() does not find best mode, part 2

Following commit 1.51, I come accross a problem when SDL must choose between
several video modes that could suit the one asked.

If I ask 320x240 with this list:
768x480 768x240 640x400 640x200 384x480 384x240 320x400 320x200

The smallest selectables modes are 384x240 and 320x400. And SDL choose the later
in this list, but 384x240 is more suitable. So I added a check to compare
the pixel count (surface) of modes, and select the one which has the smallest
pixel count.

In my example, 384x240 has 92160 pixels, and 320x400 has 128000 pixels. So now
SDL will choose 384x240 for the asked 320x240 mode.
     1  ========================
     2   Using SDL with PicoGUI
     3  ========================
     4 
     5 - Originally contributed by Micah Dowty <micahjd@users.sourceforge.net>
     6 
     7 PicoGUI is a scalable GUI system with a unique architecture, primarily focused
     8 on scalability to various embedded systems. You can find more information
     9 including a FAQ at http://picogui.org
    10 
    11 To use the patch:
    12 
    13   1. When compiling, add the "--enable-video-picogui" switch to ./configure
    14 
    15   2. When running your program, ensure that the picogui driver for SDL
    16      is in use by setting the SDL_VIDEODRIVER environment variable 
    17      to "picogui".
    18 
    19   3. The program must also be linked to the C client library for PicoGUI
    20      (libpgui.so). If the program is being compiled with a patched SDL 
    21      installed this should be done automatically. If you want to use an
    22      existing binary with PicoGUI, you can set the LD_PRELOAD environment
    23      variable to the path of your libpgui.so file.
    24 
    25 Capabilities:
    26 
    27   So far only basic functionality is provided on true color (linear16/24/32)
    28   devices. Accessing a memory mapped bitmap, updating the display, and handling
    29   mouse/keyboard input. This functionality has been tested with several
    30   applications, including mplayer, Xine, sldroids, and Abuse.
    31 
    32 TODO list:
    33 
    34   - YUV overlays will be helpful for watching video on set top boxes or other
    35     embedded devices that have some graphics acceleration hardware
    36 
    37   - Account for rotated bitmap storage in pgserver
    38 
    39   - Support for hiding or changing the cursor
    40 
    41   - The display should be centered when the SDL application is smaller
    42     than the PicoGUI panel
    43 
    44   - Fullscreen or any other special modes
    45 
    46   - Support for indexed and grayscale modes
    47 
    48   - Probably much more...
    49 
    50 --- The End ---