summaryrefslogtreecommitdiff
path: root/music
diff options
context:
space:
mode:
authortron <tron@openttd.org>2005-09-25 09:04:59 +0000
committertron <tron@openttd.org>2005-09-25 09:04:59 +0000
commitc2c865e4b9705a009b71d9cd69ce6821bc1bca72 (patch)
treed32081413d37e02ae74f2636f2ff0fa5e08da4dc /music
parent03ad234d47b72a833f88ff227acc0b698f7a2c0f (diff)
downloadopenttd-c2c865e4b9705a009b71d9cd69ce6821bc1bca72.tar.xz
(svn r2984) Use adequate types, this should aid portability a bit
Diffstat (limited to 'music')
-rw-r--r--music/extmidi.c2
-rw-r--r--music/win32_m.c9
2 files changed, 6 insertions, 5 deletions
diff --git a/music/extmidi.c b/music/extmidi.c
index d474b3acb..3f893cb46 100644
--- a/music/extmidi.c
+++ b/music/extmidi.c
@@ -17,7 +17,7 @@
static struct {
char song[MAX_PATH];
- int pid;
+ pid_t pid;
} _midi;
static void DoPlay(void);
diff --git a/music/win32_m.c b/music/win32_m.c
index 866157ee6..5e9dfbca9 100644
--- a/music/win32_m.c
+++ b/music/win32_m.c
@@ -12,7 +12,7 @@ static struct {
bool playing;
int new_vol;
HANDLE wait_obj;
- uint devid;
+ UINT_PTR devid;
char start_song[260];
} _midi;
@@ -44,7 +44,7 @@ static void Win32MidiSetVolume(byte vol)
SetEvent(_midi.wait_obj);
}
-static long CDECL MidiSendCommand(const char *cmd, ...) {
+static MCIERROR CDECL MidiSendCommand(const char *cmd, ...) {
va_list va;
char buf[512];
@@ -72,7 +72,7 @@ static void MidiIntStopSong(void)
static void MidiIntSetVolume(int vol)
{
- uint v = (vol * 65535 / 127);
+ DWORD v = (vol * 65535 / 127);
midiOutSetVolume((HMIDIOUT)_midi.devid, v + (v << 16));
}
@@ -128,7 +128,8 @@ static const char *Win32MidiStart(const char * const *parm)
{
MIDIOUTCAPS midicaps;
DWORD threadId;
- uint dev, nbdev;
+ UINT nbdev;
+ UINT_PTR dev;
char buf[16];
mciSendStringA("capability sequencer has audio", buf, lengthof(buf), 0);