diff options
Diffstat (limited to 'src/contrib/SDL-2.30.2/docs/README-directfb.md')
| -rw-r--r-- | src/contrib/SDL-2.30.2/docs/README-directfb.md | 123 | 
1 files changed, 123 insertions, 0 deletions
diff --git a/src/contrib/SDL-2.30.2/docs/README-directfb.md b/src/contrib/SDL-2.30.2/docs/README-directfb.md new file mode 100644 index 0000000..bbc6e99 --- /dev/null +++ b/src/contrib/SDL-2.30.2/docs/README-directfb.md  | |||
| @@ -0,0 +1,123 @@ | |||
| 1 | DirectFB | ||
| 2 | ======== | ||
| 3 | |||
| 4 | Supports: | ||
| 5 | |||
| 6 | - Hardware YUV overlays | ||
| 7 | - OpenGL - software only | ||
| 8 | - 2D/3D accelerations (depends on directfb driver) | ||
| 9 | - multiple displays | ||
| 10 | - windows | ||
| 11 | |||
| 12 | What you need: | ||
| 13 | |||
| 14 | * DirectFB 1.0.1, 1.2.x, 1.3.0 | ||
| 15 | * Kernel-Framebuffer support: required: vesafb, radeonfb .... | ||
| 16 | * Mesa 7.0.x - optional for OpenGL | ||
| 17 | |||
| 18 | The `/etc/directfbrc` file should contain the following lines to make | ||
| 19 | your joystick work and avoid crashes: | ||
| 20 | |||
| 21 | ``` | ||
| 22 | disable-module=joystick | ||
| 23 | disable-module=cle266 | ||
| 24 | disable-module=cyber5k | ||
| 25 | no-linux-input-grab | ||
| 26 | ``` | ||
| 27 | |||
| 28 | To disable to use x11 backend when DISPLAY variable is found use | ||
| 29 | |||
| 30 | ``` | ||
| 31 | export SDL_DIRECTFB_X11_CHECK=0 | ||
| 32 | ``` | ||
| 33 | |||
| 34 | To disable the use of linux input devices, i.e. multimice/multikeyboard support, | ||
| 35 | use | ||
| 36 | |||
| 37 | ``` | ||
| 38 | export SDL_DIRECTFB_LINUX_INPUT=0 | ||
| 39 | ``` | ||
| 40 | |||
| 41 | To use hardware accelerated YUV-overlays for YUV-textures, use: | ||
| 42 | |||
| 43 | ``` | ||
| 44 | export SDL_DIRECTFB_YUV_DIRECT=1 | ||
| 45 | ``` | ||
| 46 | |||
| 47 | This is disabled by default. It will only support one | ||
| 48 | YUV texture, namely the first. Every other YUV texture will be | ||
| 49 | rendered in software. | ||
| 50 | |||
| 51 | In addition, you may use (directfb-1.2.x) | ||
| 52 | |||
| 53 | ``` | ||
| 54 | export SDL_DIRECTFB_YUV_UNDERLAY=1 | ||
| 55 | ``` | ||
| 56 | |||
| 57 | to make the YUV texture an underlay. This will make the cursor to | ||
| 58 | be shown. | ||
| 59 | |||
| 60 | Simple Window Manager | ||
| 61 | ===================== | ||
| 62 | |||
| 63 | The driver has support for a very, very basic window manager you may | ||
| 64 | want to use when running with `wm=default`. Use | ||
| 65 | |||
| 66 | ``` | ||
| 67 | export SDL_DIRECTFB_WM=1 | ||
| 68 | ``` | ||
| 69 | |||
| 70 | to enable basic window borders. In order to have the window title rendered, | ||
| 71 | you need to have the following font installed: | ||
| 72 | |||
| 73 | ``` | ||
| 74 | /usr/share/fonts/truetype/freefont/FreeSans.ttf | ||
| 75 | ``` | ||
| 76 | |||
| 77 | OpenGL Support | ||
| 78 | ============== | ||
| 79 | |||
| 80 | The following instructions will give you *software* OpenGL. However this | ||
| 81 | works at least on all directfb supported platforms. | ||
| 82 | |||
| 83 | As of this writing 20100802 you need to pull Mesa from git and do the following: | ||
| 84 | |||
| 85 | ``` | ||
| 86 | git clone git://anongit.freedesktop.org/git/mesa/mesa | ||
| 87 | cd mesa | ||
| 88 | git checkout 2c9fdaf7292423c157fc79b5ce43f0f199dd753a | ||
| 89 | ``` | ||
| 90 | |||
| 91 | Edit `configs/linux-directfb` so that the Directories-section looks like this: | ||
| 92 | |||
| 93 | ``` | ||
| 94 | # Directories | ||
| 95 | SRC_DIRS = mesa glu | ||
| 96 | GLU_DIRS = sgi | ||
| 97 | DRIVER_DIRS = directfb | ||
| 98 | PROGRAM_DIRS = | ||
| 99 | ``` | ||
| 100 | |||
| 101 | Then do the following: | ||
| 102 | |||
| 103 | ``` | ||
| 104 | make linux-directfb | ||
| 105 | make | ||
| 106 | |||
| 107 | echo Installing - please enter sudo pw. | ||
| 108 | |||
| 109 | sudo make install INSTALL_DIR=/usr/local/dfb_GL | ||
| 110 | cd src/mesa/drivers/directfb | ||
| 111 | make | ||
| 112 | sudo make install INSTALL_DIR=/usr/local/dfb_GL | ||
| 113 | ``` | ||
| 114 | |||
| 115 | To run the SDL - testprograms: | ||
| 116 | |||
| 117 | ``` | ||
| 118 | export SDL_VIDEODRIVER=directfb | ||
| 119 | export LD_LIBRARY_PATH=/usr/local/dfb_GL/lib | ||
| 120 | export LD_PRELOAD=/usr/local/dfb_GL/libGL.so.7 | ||
| 121 | |||
| 122 | ./testgl | ||
| 123 | ``` | ||
