~facundo/enjuewemela/trunk

« back to all changes in this revision

Viewing changes to cocos/audio/SDL/constants.py

  • Committer: facundo at com
  • Date: 2011-05-14 18:13:25 UTC
  • mfrom: (67.1.4 v3rel)
  • Revision ID: facundo@taniquetil.com.ar-20110514181325-614h8kjz32w5cmoy
Refactor back

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/env python
2
 
 
3
 
'''Constants and enums for all SDL submodules.
4
 
'''
5
 
 
6
 
__docformat__ = 'restructuredtext'
7
 
__version__ = '$Id: $'
8
 
 
9
 
import sys
10
 
 
11
 
# enum SDLKey {
12
 
 
13
 
#  The keyboard syms have been cleverly chosen to map to ASCII 
14
 
SDLK_UNKNOWN            = 0
15
 
SDLK_FIRST              = 0
16
 
SDLK_BACKSPACE          = 8
17
 
SDLK_TAB                = 9
18
 
SDLK_CLEAR              = 12
19
 
SDLK_RETURN             = 13
20
 
SDLK_PAUSE              = 19
21
 
SDLK_ESCAPE             = 27
22
 
SDLK_SPACE              = 32
23
 
SDLK_EXCLAIM            = 33
24
 
SDLK_QUOTEDBL           = 34
25
 
SDLK_HASH               = 35
26
 
SDLK_DOLLAR             = 36
27
 
SDLK_AMPERSAND          = 38
28
 
SDLK_QUOTE              = 39
29
 
SDLK_LEFTPAREN          = 40
30
 
SDLK_RIGHTPAREN         = 41
31
 
SDLK_ASTERISK           = 42
32
 
SDLK_PLUS               = 43
33
 
SDLK_COMMA              = 44
34
 
SDLK_MINUS              = 45
35
 
SDLK_PERIOD             = 46
36
 
SDLK_SLASH              = 47
37
 
SDLK_0                  = 48
38
 
SDLK_1                  = 49
39
 
SDLK_2                  = 50
40
 
SDLK_3                  = 51
41
 
SDLK_4                  = 52
42
 
SDLK_5                  = 53
43
 
SDLK_6                  = 54
44
 
SDLK_7                  = 55
45
 
SDLK_8                  = 56
46
 
SDLK_9                  = 57
47
 
SDLK_COLON              = 58
48
 
SDLK_SEMICOLON          = 59
49
 
SDLK_LESS               = 60
50
 
SDLK_EQUALS             = 61
51
 
SDLK_GREATER            = 62
52
 
SDLK_QUESTION           = 63
53
 
SDLK_AT                 = 64
54
 
 
55
 
#  Skip uppercase letters
56
 
 
57
 
SDLK_LEFTBRACKET        = 91
58
 
SDLK_BACKSLASH          = 92
59
 
SDLK_RIGHTBRACKET       = 93
60
 
SDLK_CARET              = 94
61
 
SDLK_UNDERSCORE         = 95
62
 
SDLK_BACKQUOTE          = 96
63
 
SDLK_a                  = 97
64
 
SDLK_b                  = 98
65
 
SDLK_c                  = 99
66
 
SDLK_d                  = 100
67
 
SDLK_e                  = 101
68
 
SDLK_f                  = 102
69
 
SDLK_g                  = 103
70
 
SDLK_h                  = 104
71
 
SDLK_i                  = 105
72
 
SDLK_j                  = 106
73
 
SDLK_k                  = 107
74
 
SDLK_l                  = 108
75
 
SDLK_m                  = 109
76
 
SDLK_n                  = 110
77
 
SDLK_o                  = 111
78
 
SDLK_p                  = 112
79
 
SDLK_q                  = 113
80
 
SDLK_r                  = 114
81
 
SDLK_s                  = 115
82
 
SDLK_t                  = 116
83
 
SDLK_u                  = 117
84
 
SDLK_v                  = 118
85
 
SDLK_w                  = 119
86
 
SDLK_x                  = 120
87
 
SDLK_y                  = 121
88
 
SDLK_z                  = 122
89
 
SDLK_DELETE             = 127
90
 
#  End of ASCII mapped keysyms 
91
 
 
92
 
#  International keyboard syms 
93
 
SDLK_WORLD_0            = 160          #  0xA0 
94
 
SDLK_WORLD_1            = 161
95
 
SDLK_WORLD_2            = 162
96
 
SDLK_WORLD_3            = 163
97
 
SDLK_WORLD_4            = 164
98
 
SDLK_WORLD_5            = 165
99
 
SDLK_WORLD_6            = 166
100
 
SDLK_WORLD_7            = 167
101
 
SDLK_WORLD_8            = 168
102
 
SDLK_WORLD_9            = 169
103
 
SDLK_WORLD_10           = 170
104
 
SDLK_WORLD_11           = 171
105
 
SDLK_WORLD_12           = 172
106
 
SDLK_WORLD_13           = 173
107
 
SDLK_WORLD_14           = 174
108
 
SDLK_WORLD_15           = 175
109
 
SDLK_WORLD_16           = 176
110
 
SDLK_WORLD_17           = 177
111
 
SDLK_WORLD_18           = 178
112
 
SDLK_WORLD_19           = 179
113
 
SDLK_WORLD_20           = 180
114
 
SDLK_WORLD_21           = 181
115
 
SDLK_WORLD_22           = 182
116
 
SDLK_WORLD_23           = 183
117
 
SDLK_WORLD_24           = 184
118
 
SDLK_WORLD_25           = 185
119
 
SDLK_WORLD_26           = 186
120
 
SDLK_WORLD_27           = 187
121
 
SDLK_WORLD_28           = 188
122
 
SDLK_WORLD_29           = 189
123
 
SDLK_WORLD_30           = 190
124
 
SDLK_WORLD_31           = 191
125
 
SDLK_WORLD_32           = 192
126
 
SDLK_WORLD_33           = 193
127
 
SDLK_WORLD_34           = 194
128
 
SDLK_WORLD_35           = 195
129
 
SDLK_WORLD_36           = 196
130
 
SDLK_WORLD_37           = 197
131
 
SDLK_WORLD_38           = 198
132
 
SDLK_WORLD_39           = 199
133
 
SDLK_WORLD_40           = 200
134
 
SDLK_WORLD_41           = 201
135
 
SDLK_WORLD_42           = 202
136
 
SDLK_WORLD_43           = 203
137
 
SDLK_WORLD_44           = 204
138
 
SDLK_WORLD_45           = 205
139
 
SDLK_WORLD_46           = 206
140
 
SDLK_WORLD_47           = 207
141
 
SDLK_WORLD_48           = 208
142
 
SDLK_WORLD_49           = 209
143
 
SDLK_WORLD_50           = 210
144
 
SDLK_WORLD_51           = 211
145
 
SDLK_WORLD_52           = 212
146
 
SDLK_WORLD_53           = 213
147
 
SDLK_WORLD_54           = 214
148
 
SDLK_WORLD_55           = 215
149
 
SDLK_WORLD_56           = 216
150
 
SDLK_WORLD_57           = 217
151
 
SDLK_WORLD_58           = 218
152
 
SDLK_WORLD_59           = 219
153
 
SDLK_WORLD_60           = 220
154
 
SDLK_WORLD_61           = 221
155
 
SDLK_WORLD_62           = 222
156
 
SDLK_WORLD_63           = 223
157
 
SDLK_WORLD_64           = 224
158
 
SDLK_WORLD_65           = 225
159
 
SDLK_WORLD_66           = 226
160
 
SDLK_WORLD_67           = 227
161
 
SDLK_WORLD_68           = 228
162
 
SDLK_WORLD_69           = 229
163
 
SDLK_WORLD_70           = 230
164
 
SDLK_WORLD_71           = 231
165
 
SDLK_WORLD_72           = 232
166
 
SDLK_WORLD_73           = 233
167
 
SDLK_WORLD_74           = 234
168
 
SDLK_WORLD_75           = 235
169
 
SDLK_WORLD_76           = 236
170
 
SDLK_WORLD_77           = 237
171
 
SDLK_WORLD_78           = 238
172
 
SDLK_WORLD_79           = 239
173
 
SDLK_WORLD_80           = 240
174
 
SDLK_WORLD_81           = 241
175
 
SDLK_WORLD_82           = 242
176
 
SDLK_WORLD_83           = 243
177
 
SDLK_WORLD_84           = 244
178
 
SDLK_WORLD_85           = 245
179
 
SDLK_WORLD_86           = 246
180
 
SDLK_WORLD_87           = 247
181
 
SDLK_WORLD_88           = 248
182
 
SDLK_WORLD_89           = 249
183
 
SDLK_WORLD_90           = 250
184
 
SDLK_WORLD_91           = 251
185
 
SDLK_WORLD_92           = 252
186
 
SDLK_WORLD_93           = 253
187
 
SDLK_WORLD_94           = 254
188
 
SDLK_WORLD_95           = 255          #  0xFF 
189
 
 
190
 
#  Numeric keypad 
191
 
SDLK_KP0                = 256
192
 
SDLK_KP1                = 257
193
 
SDLK_KP2                = 258
194
 
SDLK_KP3                = 259
195
 
SDLK_KP4                = 260
196
 
SDLK_KP5                = 261
197
 
SDLK_KP6                = 262
198
 
SDLK_KP7                = 263
199
 
SDLK_KP8                = 264
200
 
SDLK_KP9                = 265
201
 
SDLK_KP_PERIOD          = 266
202
 
SDLK_KP_DIVIDE          = 267
203
 
SDLK_KP_MULTIPLY        = 268
204
 
SDLK_KP_MINUS           = 269
205
 
SDLK_KP_PLUS            = 270
206
 
SDLK_KP_ENTER           = 271
207
 
SDLK_KP_EQUALS          = 272
208
 
 
209
 
#  Arrows + Home/End pad 
210
 
SDLK_UP                 = 273
211
 
SDLK_DOWN               = 274
212
 
SDLK_RIGHT              = 275
213
 
SDLK_LEFT               = 276
214
 
SDLK_INSERT             = 277
215
 
SDLK_HOME               = 278
216
 
SDLK_END                = 279
217
 
SDLK_PAGEUP             = 280
218
 
SDLK_PAGEDOWN           = 281
219
 
 
220
 
#  Function keys 
221
 
SDLK_F1                 = 282
222
 
SDLK_F2                 = 283
223
 
SDLK_F3                 = 284
224
 
SDLK_F4                 = 285
225
 
SDLK_F5                 = 286
226
 
SDLK_F6                 = 287
227
 
SDLK_F7                 = 288
228
 
SDLK_F8                 = 289
229
 
SDLK_F9                 = 290
230
 
SDLK_F10                = 291
231
 
SDLK_F11                = 292
232
 
SDLK_F12                = 293
233
 
SDLK_F13                = 294
234
 
SDLK_F14                = 295
235
 
SDLK_F15                = 296
236
 
 
237
 
#  Key state modifier keys 
238
 
SDLK_NUMLOCK            = 300
239
 
SDLK_CAPSLOCK           = 301
240
 
SDLK_SCROLLOCK          = 302
241
 
SDLK_RSHIFT             = 303
242
 
SDLK_LSHIFT             = 304
243
 
SDLK_RCTRL              = 305
244
 
SDLK_LCTRL              = 306
245
 
SDLK_RALT               = 307
246
 
SDLK_LALT               = 308
247
 
SDLK_RMETA              = 309
248
 
SDLK_LMETA              = 310
249
 
SDLK_LSUPER             = 311          #  Left "Windows" key 
250
 
SDLK_RSUPER             = 312          #  Right "Windows" key 
251
 
SDLK_MODE               = 313          #  "Alt Gr" key 
252
 
SDLK_COMPOSE            = 314          #  Multi-key compose key 
253
 
 
254
 
#  Miscellaneous function keys 
255
 
SDLK_HELP               = 315
256
 
SDLK_PRINT              = 316
257
 
SDLK_SYSREQ             = 317
258
 
SDLK_BREAK              = 318
259
 
SDLK_MENU               = 319
260
 
SDLK_POWER              = 320          #  Power Macintosh power key 
261
 
SDLK_EURO               = 321          #  Some european keyboards 
262
 
SDLK_UNDO               = 322          #  Atari keyboard has Undo 
263
 
 
264
 
SDLK_LAST               = 323          #  Keep me updated please.
265
 
 
266
 
# end of enum SDLKey
267
 
 
268
 
# enum SDLMod
269
 
 
270
 
KMOD_NONE       = 0x0000
271
 
KMOD_LSHIFT     = 0x0001
272
 
KMOD_RSHIFT     = 0x0002
273
 
KMOD_LCTRL      = 0x0040
274
 
KMOD_RCTRL      = 0x0080
275
 
KMOD_LALT       = 0x0100
276
 
KMOD_RALT       = 0x0200
277
 
KMOD_LMETA      = 0x0400
278
 
KMOD_RMETA      = 0x0800
279
 
KMOD_NUM        = 0x1000
280
 
KMOD_CAPS       = 0x2000
281
 
KMOD_MODE       = 0x4000
282
 
KMOD_RESERVED   = 0x8000
283
 
 
284
 
# end of enum SDLMod
285
 
 
286
 
KMOD_CTRL   = KMOD_LCTRL    | KMOD_RCTRL
287
 
KMOD_SHIFT  = KMOD_LSHIFT   | KMOD_RSHIFT
288
 
KMOD_ALT    = KMOD_LALT     | KMOD_RALT
289
 
KMOD_META   = KMOD_LMETA    | KMOD_RMETA
290
 
 
291
 
#BEGIN GENERATED CONSTANTS; see support/make_constants.py
292
 
 
293
 
#Constants from SDL_mouse.h:
294
 
SDL_BUTTON_LEFT = 0x00000001
295
 
SDL_BUTTON_MIDDLE = 0x00000002
296
 
SDL_BUTTON_RIGHT = 0x00000003
297
 
SDL_BUTTON_WHEELUP = 0x00000004
298
 
SDL_BUTTON_WHEELDOWN = 0x00000005
299
 
 
300
 
#Constants from SDL_version.h:
301
 
SDL_MAJOR_VERSION = 0x00000001
302
 
SDL_MINOR_VERSION = 0x00000002
303
 
SDL_PATCHLEVEL = 0x0000000a
304
 
 
305
 
#Constants from SDL.h:
306
 
SDL_INIT_TIMER = 0x00000001
307
 
SDL_INIT_AUDIO = 0x00000010
308
 
SDL_INIT_VIDEO = 0x00000020
309
 
SDL_INIT_CDROM = 0x00000100
310
 
SDL_INIT_JOYSTICK = 0x00000200
311
 
SDL_INIT_NOPARACHUTE = 0x00100000
312
 
SDL_INIT_EVENTTHREAD = 0x01000000
313
 
SDL_INIT_EVERYTHING = 0x0000ffff
314
 
 
315
 
#Constants from SDL_mutex.h:
316
 
SDL_MUTEX_TIMEDOUT = 0x00000001
317
 
 
318
 
#Constants from SDL_video.h:
319
 
SDL_ALPHA_OPAQUE = 0x000000ff
320
 
SDL_ALPHA_TRANSPARENT = 0x00000000
321
 
SDL_SWSURFACE = 0x00000000
322
 
SDL_HWSURFACE = 0x00000001
323
 
SDL_ASYNCBLIT = 0x00000004
324
 
SDL_ANYFORMAT = 0x10000000
325
 
SDL_HWPALETTE = 0x20000000
326
 
SDL_DOUBLEBUF = 0x40000000
327
 
SDL_FULLSCREEN = 0x80000000
328
 
SDL_OPENGL = 0x00000002
329
 
SDL_OPENGLBLIT = 0x0000000a
330
 
SDL_RESIZABLE = 0x00000010
331
 
SDL_NOFRAME = 0x00000020
332
 
SDL_HWACCEL = 0x00000100
333
 
SDL_SRCCOLORKEY = 0x00001000
334
 
SDL_RLEACCELOK = 0x00002000
335
 
SDL_RLEACCEL = 0x00004000
336
 
SDL_SRCALPHA = 0x00010000
337
 
SDL_PREALLOC = 0x01000000
338
 
SDL_YV12_OVERLAY = 0x32315659
339
 
SDL_IYUV_OVERLAY = 0x56555949
340
 
SDL_YUY2_OVERLAY = 0x32595559
341
 
SDL_UYVY_OVERLAY = 0x59565955
342
 
SDL_YVYU_OVERLAY = 0x55595659
343
 
SDL_LOGPAL = 0x00000001
344
 
SDL_PHYSPAL = 0x00000002
345
 
 
346
 
#Constants from SDL_name.h:
347
 
NeedFunctionPrototypes = 0x00000001
348
 
 
349
 
#Constants from SDL_endian.h:
350
 
SDL_LIL_ENDIAN = 0x000004d2
351
 
SDL_BIG_ENDIAN = 0x000010e1
352
 
 
353
 
#Constants from SDL_audio.h:
354
 
AUDIO_U8 = 0x00000008
355
 
AUDIO_S8 = 0x00008008
356
 
AUDIO_U16LSB = 0x00000010
357
 
AUDIO_S16LSB = 0x00008010
358
 
AUDIO_U16MSB = 0x00001010
359
 
AUDIO_S16MSB = 0x00009010
360
 
SDL_MIX_MAXVOLUME = 0x00000080
361
 
 
362
 
#Constants from begin_code.h:
363
 
NULL = 0x00000000
364
 
 
365
 
#Constants from SDL_cdrom.h:
366
 
SDL_MAX_TRACKS = 0x00000063
367
 
SDL_AUDIO_TRACK = 0x00000000
368
 
SDL_DATA_TRACK = 0x00000004
369
 
CD_FPS = 0x0000004b
370
 
 
371
 
#Constants from SDL_events.h:
372
 
SDL_RELEASED = 0x00000000
373
 
SDL_PRESSED = 0x00000001
374
 
SDL_ALLEVENTS = 0xffffffff
375
 
SDL_IGNORE = 0x00000000
376
 
SDL_DISABLE = 0x00000000
377
 
SDL_ENABLE = 0x00000001
378
 
 
379
 
#Constants from SDL_active.h:
380
 
SDL_APPMOUSEFOCUS = 0x00000001
381
 
SDL_APPINPUTFOCUS = 0x00000002
382
 
SDL_APPACTIVE = 0x00000004
383
 
 
384
 
#Constants from SDL_joystick.h:
385
 
SDL_HAT_CENTERED = 0x00000000
386
 
SDL_HAT_UP = 0x00000001
387
 
SDL_HAT_RIGHT = 0x00000002
388
 
SDL_HAT_DOWN = 0x00000004
389
 
SDL_HAT_LEFT = 0x00000008
390
 
 
391
 
#Constants from SDL_keyboard.h:
392
 
SDL_ALL_HOTKEYS = 0xffffffff
393
 
SDL_DEFAULT_REPEAT_DELAY = 0x000001f4
394
 
SDL_DEFAULT_REPEAT_INTERVAL = 0x0000001e
395
 
 
396
 
#Constants from SDL_rwops.h:
397
 
RW_SEEK_SET = 0x00000000
398
 
RW_SEEK_CUR = 0x00000001
399
 
RW_SEEK_END = 0x00000002
400
 
 
401
 
#Constants from SDL_timer.h:
402
 
SDL_TIMESLICE = 0x0000000a
403
 
TIMER_RESOLUTION = 0x0000000a
404
 
#END GENERATED CONSTANTS
405
 
 
406
 
# From SDL_audio.h (inserted manually)
407
 
 
408
 
# enum SDL_audiostatus
409
 
(SDL_AUDIO_STOPPED,
410
 
    SDL_AUDIO_PLAYING,
411
 
    SDL_AUDIO_PAUSED) = range(3)
412
 
 
413
 
if sys.byteorder == 'little':
414
 
    AUDIO_U16SYS = AUDIO_U16LSB
415
 
    AUDIO_S16SYS = AUDIO_S16LSB
416
 
else:
417
 
    AUDIO_U16SYS = AUDIO_U16MSB
418
 
    AUDIO_S16SYS = AUDIO_S16MSB
419
 
AUDIO_U16 = AUDIO_U16LSB
420
 
AUDIO_S16 = AUDIO_S16LSB
421
 
 
422
 
# From SDL_cdrom.h (inserted manually)
423
 
# enum CDstatus
424
 
(CD_TRAYEMPTY,
425
 
    CD_STOPPED,
426
 
    CD_PLAYING,
427
 
    CD_PAUSED) = range(4)
428
 
CD_ERROR = -1
429
 
 
430
 
# From SDL_events.h (inserted manually)
431
 
# enum SDL_EventType
432
 
(SDL_NOEVENT,
433
 
    SDL_ACTIVEEVENT,
434
 
    SDL_KEYDOWN,
435
 
    SDL_KEYUP,
436
 
    SDL_MOUSEMOTION,
437
 
    SDL_MOUSEBUTTONDOWN,
438
 
    SDL_MOUSEBUTTONUP,
439
 
    SDL_JOYAXISMOTION,
440
 
    SDL_JOYBALLMOTION,
441
 
    SDL_JOYHATMOTION,
442
 
    SDL_JOYBUTTONDOWN,
443
 
    SDL_JOYBUTTONUP,
444
 
    SDL_QUIT,
445
 
    SDL_SYSWMEVENT,
446
 
    SDL_EVENT_RESERVEDA,
447
 
    SDL_EVENT_RESERVEDB,
448
 
    SDL_VIDEORESIZE,
449
 
    SDL_VIDEOEXPOSE,
450
 
    SDL_EVENT_RESERVED2,
451
 
    SDL_EVENT_RESERVED3,
452
 
    SDL_EVENT_RESERVED4,
453
 
    SDL_EVENT_RESERVED5,
454
 
    SDL_EVENT_RESERVED6,
455
 
    SDL_EVENT_RESERVED7) = range(24)
456
 
SDL_USEREVENT = 24
457
 
SDL_NUMEVENTS = 32
458
 
 
459
 
def SDL_EVENTMASK(x):
460
 
    '''Used for predefining event masks.'''
461
 
    return 1 << x
462
 
 
463
 
# enum SDL_EventMask
464
 
SDL_ACTIVEEVENTMASK     = SDL_EVENTMASK(SDL_ACTIVEEVENT)
465
 
SDL_KEYDOWNMASK         = SDL_EVENTMASK(SDL_KEYDOWN)
466
 
SDL_KEYUPMASK           = SDL_EVENTMASK(SDL_KEYUP)
467
 
SDL_KEYEVENTMASK        = SDL_KEYUPMASK | \
468
 
                          SDL_KEYDOWNMASK
469
 
SDL_MOUSEMOTIONMASK     = SDL_EVENTMASK(SDL_MOUSEMOTION)
470
 
SDL_MOUSEBUTTONDOWNMASK = SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN)
471
 
SDL_MOUSEBUTTONUPMASK   = SDL_EVENTMASK(SDL_MOUSEBUTTONUP)
472
 
SDL_MOUSEEVENTMASK      = SDL_MOUSEMOTIONMASK | \
473
 
                          SDL_MOUSEBUTTONDOWNMASK | \
474
 
                          SDL_MOUSEBUTTONUPMASK
475
 
SDL_JOYAXISMOTIONMASK   = SDL_EVENTMASK(SDL_JOYAXISMOTION)
476
 
SDL_JOYBALLMOTIONMASK   = SDL_EVENTMASK(SDL_JOYBALLMOTION)
477
 
SDL_JOYHATMOTIONMASK    = SDL_EVENTMASK(SDL_JOYHATMOTION)
478
 
SDL_JOYBUTTONDOWNMASK   = SDL_EVENTMASK(SDL_JOYBUTTONDOWN)
479
 
SDL_JOYBUTTONUPMASK     = SDL_EVENTMASK(SDL_JOYBUTTONUP)
480
 
SDL_JOYEVENTMASK        = SDL_JOYAXISMOTIONMASK | \
481
 
                          SDL_JOYBALLMOTIONMASK | \
482
 
                          SDL_JOYHATMOTIONMASK | \
483
 
                          SDL_JOYBUTTONDOWNMASK | \
484
 
                          SDL_JOYBUTTONUPMASK
485
 
SDL_QUITMASK            = SDL_EVENTMASK(SDL_QUIT)
486
 
SDL_SYSWMEVENTMASK      = SDL_EVENTMASK(SDL_SYSWMEVENT)
487
 
SDL_VIDEORESIZEMASK     = SDL_EVENTMASK(SDL_VIDEORESIZE)
488
 
SDL_VIDEOEXPOSEMASK     = SDL_EVENTMASK(SDL_VIDEOEXPOSE)
489
 
 
490
 
# enum SDL_eventaction
491
 
(SDL_ADDEVENT,
492
 
    SDL_PEEKEVENT,
493
 
    SDL_GETEVENT) = range(3)
494
 
 
495
 
#From SDL_joystick.h (inserted manually)
496
 
SDL_HAT_RIGHTUP = SDL_HAT_RIGHT | SDL_HAT_UP
497
 
SDL_HAT_RIGHTDOWN = SDL_HAT_RIGHT | SDL_HAT_DOWN
498
 
SDL_HAT_LEFTUP = SDL_HAT_LEFT | SDL_HAT_UP
499
 
SDL_HAT_LEFTDOWN = SDL_HAT_LEFT | SDL_HAT_DOWN
500
 
 
501
 
# From SDL_video.h (inserted manually)
502
 
# enum SDL_GLattr
503
 
(SDL_GL_RED_SIZE,
504
 
    SDL_GL_GREEN_SIZE,
505
 
    SDL_GL_BLUE_SIZE,
506
 
    SDL_GL_ALPHA_SIZE,
507
 
    SDL_GL_BUFFER_SIZE,
508
 
    SDL_GL_DOUBLEBUFFER,
509
 
    SDL_GL_DEPTH_SIZE,
510
 
    SDL_GL_STENCIL_SIZE,
511
 
    SDL_GL_ACCUM_RED_SIZE,
512
 
    SDL_GL_ACCUM_GREEN_SIZE,
513
 
    SDL_GL_ACCUM_BLUE_SIZE,
514
 
    SDL_GL_ACCUM_ALPHA_SIZE,
515
 
    SDL_GL_STEREO,
516
 
    SDL_GL_MULTISAMPLEBUFFERS,
517
 
    SDL_GL_MULTISAMPLESAMPLES,
518
 
    SDL_GL_ACCELERATED_VISUAL,
519
 
    SDL_GL_SWAP_CONTROL) = range(17)
520
 
 
521
 
# enum SDL_GrabMode
522
 
(SDL_GRAB_QUERY,
523
 
    SDL_GRAB_OFF,
524
 
    SDL_GRAB_ON) = range(-1,2)
525
 
 
526
 
# From SDL_ttf.h (inserted manually)
527
 
TTF_STYLE_NORMAL    = 0x00
528
 
TTF_STYLE_BOLD      = 0x01
529
 
TTF_STYLE_ITALIC    = 0x02
530
 
TTF_STYLE_UNDERLINE = 0x04
531
 
 
532
 
# From SDL_mixer.h (inserted manually)
533
 
MIX_CHANNELS            = 8
534
 
MIX_DEFAULT_FREQUENCY   = 22050
535
 
MIX_MAX_VOLUME          = 128
536
 
MIX_CHANNEL_POST        = -2
537
 
MIX_EFFECTSMAXSPEED     = 'MIX_EFFECTSMAXSPEED'
538
 
MIX_DEFAULT_CHANNELS    = 2
539
 
 
540
 
if sys.byteorder == 'little':
541
 
    MIX_DEFAULT_FORMAT  = AUDIO_S16LSB 
542
 
else:
543
 
    MIX_DEFAULT_FORMAT  = AUDIO_S16MSB
544
 
 
545
 
# enum Mix_Fading
546
 
(MIX_NO_FADING,
547
 
    MIX_FADING_OUT,
548
 
    MIX_FADING_IN) = range(3)
549
 
 
550
 
# enum Mix_MusicType
551
 
(MUS_NONE,
552
 
    MUS_CMD,
553
 
    MUS_WAV,
554
 
    MUS_MOD,
555
 
    MUS_MID,
556
 
    MUS_OGG,
557
 
    MUS_MP3) = range(7)
558
 
 
559
 
# From SDL_sound.h (inserted manually):
560
 
# enum Sound_SampleFlags
561
 
SOUND_SAMPLEFLAG_NONE       = 0
562
 
SOUND_SAMPLEFLAG_CANSEEK    = 1
563
 
SOUND_SAMPLEFLAG_EOF        = 1 << 29
564
 
SOUND_SAMPLEFLAG_ERROR      = 1 << 30
565
 
SOUND_SAMPLEFLAG_EGAIN      = 1 << 31