annotate README @ 43:093315d84a22

Add a small delay in SDL audio pseudo-loopflush function to avoid tightlooping in prod main loops (explained better in the added comment.)
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 24 May 2010 05:07:33 +0300
parents 5828a0cb4d10
children ec1bff613ae0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
39
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
1
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
2 MMmmmmmmMM
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
3 MM
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
4 xxxxxxxxxxxx
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
5 xxxxxxxxxxxxxxxxxxx
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
6 xxxxxxxxx
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
7 ZZZZZ.... %%%%%%%%% %%% %%% %%%%%%%%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
8 @@@@...... %%%%%%%%%. %%%....... %%%. %%%%%%%%%....
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
9 @@@@....o. .....%%% %%% %%% %%% %%% %%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
10 @@@@@@@.... %%% %%% %%% %%% %%% %%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
11 @@@@@@@@@@@ %%%% %%% %%% %%% %%% %%%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
12 @@@@@@@@@@@@@ %%%% %%% %%% %%% %%% %%%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
13 @@@@@@@@@@@@@@@ %%%%%%%%% %%% %%% %%% %%%%%%%%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
14 @@@@ %%%%%%%%% %%% %%% %%% %%%%%%%%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
15 @@@@@@ %%% %%%%% %%% %%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
16 @@@@@@@@@@ xx %%% %%%%% %%% %%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
17 @@@@@@@@@@@@@@ %%% %%%%% %%%% %%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
18 @@@@@@@@@@@ %%% %%%%% %%%% %%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
19 @@@@@@@@@ .....%%%....... %%%%%%%%%%%%%%. %%%..........
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
20 @@@@@ %%% %%%%%%%%%%%%%% %%%
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
21 @@@@
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
22
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
23 libSDL-enhanced pwplib
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
24
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
25
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
26 Original pwplib 1.90 and everything else by viznut/pwp
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
27
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
28 SDL-support, cleanups, bugfixes and new buildsystem by ccr/TNSP^pwp
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
29
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
30
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
31 About
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
32 =====
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
33 The product at your fingertips is a cleaned up, slightly fixed
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
34 version of pwplib and everything else that came in pwpunix-1.90
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
35 package. It has been enhanced with libSDL support for video and
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
36 audio.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
37
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
38 Why, some may ask -- the reason is simple: most of terminal-based
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
39 output methods provided by original pwplib do not work very well
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
40 in current UNIX systems, and adding support for graphical output
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
41 via libSDL seemed to be the easiest way to fix this.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
42
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
43 Additionally sound support via SDL was introduced, and it is
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
44 possible to cross-compile the whole thing for Win32 via MinGW
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
45 hosted on Linux or other UNIX-ish platform.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
46
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
47
41
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
48 Usage
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
49 =====
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
50 Information about available options can be viewed via:
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
51
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
52 > peluce help
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
53
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
54 Unfortunately (or fortunately) SDL for Windows redirects stdout and
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
55 stderr by default, thus the help output goes to file "stdout.txt".
5828a0cb4d10 Add some more documentation.
Matti Hamalainen <ccr@tnsp.org>
parents: 39
diff changeset
56
39
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
57 By default the SDL target runs in a window of 640x480, but this
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
58 can be changed via commandline parameters. For example:
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
59
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
60 > peluce xres 1024 yres 768
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
61
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
62 Or run in full screen:
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
63
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
64 > peluce xres 1024 yres 768 fs
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
65
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
66
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
67 Requirements
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
68 ============
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
69
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
70 * libSDL for the SDL version.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
71
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
72 * A working C compiler (preferably GCC3 or later)
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
73
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
74 * Make (GNU Make 3.81 or later works at least)
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
75
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
76 * POSIX-ish platform for building. Windows targets
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
77 can be built via cross-compilation.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
78
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
79 Quick and dirty guide to make it: Just type 'make'
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
80 and follow the instructions.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
81
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
82 The Windows cross-compilation targets most likely require
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
83 manual intervention, e.g. editing of the Makefile as this
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
84 has only been tested on one system.
f17a3dc38f2a New documentation.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
85