README.DirectFB
author Sam Lantinga <slouken@libsdl.org>
Sat, 12 Dec 2009 01:04:57 +0000
changeset 3548 79af7b478fae
parent 3023 d72a0dd80e8b
child 4636 b196d2758026
permissions -rw-r--r--
Removed the obsolete testcdrom target
slouken@2226
     1
SDL on DirectFB
slouken@2226
     2
slouken@2226
     3
Supports:
slouken@2226
     4
slouken@2226
     5
- Hardware YUV overlays
slouken@2226
     6
- OpenGL - software only
slouken@2226
     7
- 2D/3D accelerations (depends on directfb driver)
slouken@2815
     8
- multiple displays
slouken@2815
     9
- windows
slouken@2226
    10
slouken@2226
    11
What you need:
slouken@2226
    12
slouken@2815
    13
DirectFB 1.0.1, 1.2.x, 1.3.0
slouken@2226
    14
Kernel-Framebuffer support: required: vesafb, radeonfb .... 
slouken@2226
    15
Mesa 7.0.x	   - optional for OpenGL
slouken@2226
    16
slouken@2815
    17
/etc/directfbrc
slouken@2815
    18
slouken@2815
    19
This file should contain the following lines to make
slouken@2815
    20
your joystick work and avoid crashes:
slouken@2815
    21
------------------------
slouken@2815
    22
disable-module=joystick
slouken@2815
    23
disable-module=cle266
slouken@2815
    24
disable-module=cyber5k
slouken@2998
    25
no-linux-input-grab
slouken@2815
    26
------------------------
slouken@2815
    27
slouken@2998
    28
To disable to use x11 backend when DISPLAY variable is found use
slouken@2998
    29
slouken@2998
    30
export SDL_DIRECTFB_X11_CHECK=0
slouken@2998
    31
slouken@2998
    32
To disable the use of linux input devices, i.e. multimice/multikeyboard support,
slouken@2998
    33
use
slouken@2998
    34
slouken@2998
    35
export SDL_DIRECTFB_LINUX_INPUT=0
slouken@2998
    36
slouken@2815
    37
To use hardware accelerated YUV-overlays for YUV-textures, use:
slouken@2815
    38
slouken@2815
    39
export SDL_DIRECTFB_YUV_DIRECT=1
slouken@2815
    40
slouken@2815
    41
This is disabled by default. It will only support one 
slouken@2815
    42
YUV texture, namely the first. Every other YUV texture will be
slouken@2815
    43
rendered in software.
slouken@2815
    44
slouken@2815
    45
In addition, you may use (directfb-1.2.x)
slouken@2815
    46
slouken@2815
    47
export SDL_DIRECTFB_YUV_UNDERLAY=1
slouken@2815
    48
slouken@2815
    49
to make the YUV texture an underlay. This will make the cursor to
slouken@2815
    50
be shown.
slouken@2815
    51
couriersud@3023
    52
Simple Window Manager
couriersud@3023
    53
=====================
couriersud@3023
    54
couriersud@3023
    55
The driver has support for a very, very basic window manager you may
couriersud@3023
    56
want to use when runnning with "wm=default". Use
couriersud@3023
    57
couriersud@3023
    58
export SDL_DIRECTFB_WM=1
couriersud@3023
    59
couriersud@3023
    60
to enable basic window borders. In order to have the window title rendered,
couriersud@3023
    61
you need to have the following font installed:
couriersud@3023
    62
couriersud@3023
    63
/usr/share/fonts/truetype/freefont/FreeSans.ttf
couriersud@3023
    64
slouken@2815
    65
OPENGL Support
slouken@2815
    66
==============
slouken@2815
    67
slouken@2226
    68
As of this writing 20070810 you need to pull Mesa from git and do the following:
slouken@2226
    69
slouken@2226
    70
------------------------
slouken@2226
    71
cd mesa 
slouken@2226
    72
make linux-directfb
slouken@2226
    73
make
slouken@2226
    74
slouken@2815
    75
echo Installing - please enter sudo pw.
slouken@2226
    76
slouken@2226
    77
sudo make install INSTALL_DIR=/usr/local/dfb_GL
slouken@2226
    78
cd src/mesa/drivers/directfb
slouken@2226
    79
make
slouken@2226
    80
sudo make install INSTALL_DIR=/usr/local/dfb_GL
slouken@2226
    81
------------------------
slouken@2226
    82
slouken@2226
    83
To run the SDL - testprograms:
slouken@2226
    84
slouken@2226
    85
export SDL_VIDEODRIVER=directfb
slouken@2226
    86
export LD_LIBRARY_PATH=/usr/local/dfb_GL/lib
slouken@2226
    87
export LD_PRELOAD=/usr/local/dfb_GL/libGL.so.7
slouken@2226
    88
slouken@2226
    89
./testgl