equal
deleted
inserted
replaced
18 |
18 |
19 #include <stdio.h> |
19 #include <stdio.h> |
20 #include <stdlib.h> |
20 #include <stdlib.h> |
21 #include "al.h" |
21 #include "al.h" |
22 |
22 |
|
23 #ifndef _WIN32 |
|
24 #include <pthread.h> |
|
25 #include <stdint.h> |
|
26 #else |
|
27 #define WIN32_LEAN_AND_MEAN |
|
28 #include <windows.h> |
|
29 #include "winstdint.h" |
|
30 #endif |
|
31 |
|
32 #ifndef _SLEEP_H |
|
33 #define _SLEEP_H |
|
34 /** 1.0 02/03/10 - Defines cross-platform sleep, usleep, etc. * By Wu Yongwei **/ |
|
35 #ifdef _WIN32 |
|
36 # if defined(_NEED_SLEEP_ONLY) && (defined(_MSC_VER) || defined(__MINGW32__)) |
|
37 # include <stdlib.h> |
|
38 # define sleep(t) _sleep((t) * 1000) |
|
39 # else |
|
40 # include <windows.h> |
|
41 # define sleep(t) Sleep((t) * 1000) |
|
42 # endif |
|
43 # ifndef _NEED_SLEEP_ONLY |
|
44 # define msleep(t) Sleep(t) |
|
45 # define usleep(t) Sleep((t) / 1000) |
|
46 # endif |
|
47 #else |
|
48 # include <unistd.h> |
|
49 # ifndef _NEED_SLEEP_ONLY |
|
50 # define msleep(t) usleep((t) * 1000) |
|
51 # endif |
|
52 #endif |
|
53 #endif /* _SLEEP_H */ |
|
54 |
|
55 #pragma once |
|
56 |
|
57 typedef struct _fade_t { |
|
58 int index; |
|
59 unsigned int quantity; |
|
60 } fade_t; |
|
61 |
23 void *Malloc (size_t nbytes); |
62 void *Malloc (size_t nbytes); |
24 FILE *Fopen (const char *fname, char *mode); |
63 FILE *Fopen (const char *fname, char *mode); |
25 ALint AlGetError (const char *str); |
64 ALint AlGetError (const char *str); |
|
65 #ifndef _WIN32 |
|
66 void *helper_fadein (void *tmp); |
|
67 void *helper_fadeout (void *tmp); |
|
68 #else |
|
69 void WINAPI helper_fadein (void *tmp); |
|
70 void WINAPI helper_fadeout (void *tmp); |
|
71 #endif |