README.OS2
changeset 1190 173c063d4f55
child 1442 e3242177fe4a
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/README.OS2	Wed Nov 23 07:29:56 2005 +0000
     1.3 @@ -0,0 +1,133 @@
     1.4 +
     1.5 +===========
     1.6 +SDL on OS/2
     1.7 +===========
     1.8 +
     1.9 +Last updated on Oct 02, 2005.
    1.10 +
    1.11 +
    1.12 +1. How to compile?
    1.13 +------------------
    1.14 +
    1.15 +To compile this, you'll need the followings installed:
    1.16 +- The OS/2 Developer's Toolkit
    1.17 +- The OpenWatcom compiler 
    1.18 +  (http://www.openwatcom.org)
    1.19 +- The FSLib library
    1.20 +  (ftp://ftp.netlabs.org/pub/SDL)
    1.21 +
    1.22 +Please edit the second, fourth and fifth lines of setvars.cmd file
    1.23 +to set the folders where the toolkit, the OW compiler and the FSLib are. 
    1.24 +You won't need NASM yet (The Netwide Assembler), you can leave that line.
    1.25 +Run setvars.cmd, and you should get a shell in which you can
    1.26 +compile SDL.
    1.27 +
    1.28 +Check the "Watcom.mif" file. This is the file which is included by all the
    1.29 +Watcom makefiles, so changes here will affect the whole build process.
    1.30 +There is a line in there which determines if the resulting SDL.DLL will be
    1.31 +a 'debug' or a 'release' build. The 'debug' version is full of printf()'s,
    1.32 +so if something goes wrong, its output can help a lot for debugging.
    1.33 +
    1.34 +Then go to the 'src' folder, and run "wmake -f makefile.wat".
    1.35 +This should create the SDL.DLL and the corresponding SDL.LIB file there.
    1.36 +
    1.37 +To test applications, it's a good idea to use the 'debug' build of SDL, and
    1.38 +redirect the standard output and standard error output to files, to see what
    1.39 +happens internally in SDL.
    1.40 +(like: testsprite >stdout.txt 2>stderr.txt)
    1.41 +
    1.42 +To rebuild SDL, use the following commands in 'src' folder:
    1.43 +wmake -f makefile.wat clean
    1.44 +wmake -f makefile.wat
    1.45 +
    1.46 +
    1.47 +
    1.48 +2. How to compile the testapps?
    1.49 +-------------------------------
    1.50 +
    1.51 +Once you have SDL.DLL compiled, navigate into the 'test' folder, copy in there
    1.52 +the newly built SDL.DLL, and copy in there FSLib.DLL.
    1.53 +
    1.54 +Then run "wmake -f makefile.wat" in there to compile some of the testapps.
    1.55 +
    1.56 +
    1.57 +
    1.58 +3. What is missing?
    1.59 +-------------------
    1.60 +
    1.61 +The following things are missing from this SDL implementation:
    1.62 +- MMX, SSE and 3DNOW! optimized video blitters?
    1.63 +- HW Video surfaces
    1.64 +- OpenGL support
    1.65 +
    1.66 +
    1.67 +
    1.68 +4. Special Keys / Full-Screen support
    1.69 +-------------------------------------
    1.70 +
    1.71 +There are two special hot-keys implemented:
    1.72 +- Alt+Home switches between fullscreen and windowed mode
    1.73 +- Alt+End simulates closing the window (can be used as a Panic key)
    1.74 +Only the LEFT Alt key will work.
    1.75 +
    1.76 +
    1.77 +
    1.78 +5. Joysticks on SDL/2
    1.79 +---------------------
    1.80 +
    1.81 +The Joystick detection only works for standard joysticks (2 buttons, 2 axes
    1.82 +and the like). Therefore, if you use a non-standard joystick, you should
    1.83 +specify its features in the SDL_OS2_JOYSTICK environment variable in a batch
    1.84 +file or CONFIG.SYS, so SDL applications can provide full capability to your
    1.85 +device. The syntax is:
    1.86 +
    1.87 +SET SDL_OS2_JOYSTICK=[JOYSTICK_NAME] [AXES] [BUTTONS] [HATS] [BALLS]
    1.88 +
    1.89 +So, it you have a Gravis GamePad with 4 axes, 2 buttons, 2 hats and 0 balls,
    1.90 +the line should be:
    1.91 +
    1.92 +SET SDL_OS2_JOYSTICK=Gravis_GamePad 4 2 2 0
    1.93 +
    1.94 +If you want to add spaces in your joystick name, just surround it with
    1.95 +quotes or double-quotes:
    1.96 +
    1.97 +SET SDL_OS2_JOYSTICK='Gravis GamePad' 4 2 2 0
    1.98 +
    1.99 +or
   1.100 +
   1.101 +SET SDL_OS2_JOYSTICK="Gravis GamePad" 4 2 2 0
   1.102 +
   1.103 +   Notive However that Balls and Hats are not supported under OS/2, and the
   1.104 +value will be ignored... but it is wise to define these correctly because 
   1.105 +in the future those can be supported.
   1.106 +   Also the number of buttons is limited to 2 when using two joysticks,
   1.107 +4 when using one joystick with 4 axes, 6 when using a joystick with 3 axes
   1.108 +and 8 when using a joystick with 2 axes. Notice however these are limitations 
   1.109 +of the Joystick Port hardware, not OS/2.
   1.110 +
   1.111 +
   1.112 +
   1.113 +6. Next steps...
   1.114 +----------------
   1.115 +
   1.116 +Things to do:
   1.117 +- Implement missing stuffs (look for 'TODO' string in source code!)
   1.118 +- Finish video driver (the 'wincommon' can be a good example for missing
   1.119 +  things like application icon and so on...)
   1.120 +- Enable MMX/SSE/SSE2 acceleration functions
   1.121 +- Rewrite CDROM support using DOS Ioctl for better support.
   1.122 +
   1.123 +
   1.124 +
   1.125 +7. Contacts
   1.126 +-----------
   1.127 +
   1.128 +   You can contact the developers for bugs:
   1.129 +
   1.130 +   Area					Developer		email
   1.131 +   General (Audio/Video/System)		Doodle			doodle@scenergy.dfmk.hu
   1.132 +   CDROM and Joystick			Caetano			daniel@caetano.eng.br
   1.133 +
   1.134 +   Notice however that SDL/2 is 'in development' stage so ... if you want to help,
   1.135 +please, be our guest and contact us!
   1.136 +