music.c
changeset 100 110d1c8470fa
parent 98 f00eb57224a5
child 101 1b8c88a28df8
     1.1 --- a/music.c	Sun Aug 19 22:17:46 2001 +0000
     1.2 +++ b/music.c	Sun Aug 19 23:00:30 2001 +0000
     1.3 @@ -308,7 +308,6 @@
     1.4  		}
     1.5  		md_mode |= DMODE_STEREO;
     1.6  	}
     1.7 -	samplesize	 = mixer->size/mixer->samples;
     1.8  	md_mixfreq	 = mixer->freq;
     1.9  	md_device	  = 0;
    1.10  	md_volume	  = 96;
    1.11 @@ -325,21 +324,18 @@
    1.12  #endif
    1.13  #ifdef MID_MUSIC
    1.14  	samplesize = mixer->size/mixer->samples;
    1.15 -#ifdef USE_NATIVE_MIDI
    1.16 -	if ( native_midi_init() ) {
    1.17 -		native_midi_ok = 1;
    1.18 +	if ( Timidity_Init(mixer->freq, mixer->format,
    1.19 +	                    mixer->channels, mixer->samples) != 0 ) {
    1.20 +		timidity_ok = 1;
    1.21  	} else {
    1.22 -		native_midi_ok = 0;
    1.23 -	}
    1.24 -	timidity_ok = !native_midi_ok;
    1.25 -#else
    1.26 -	timidity_ok = 1;
    1.27 -#endif
    1.28 -	if ( timidity_ok &&
    1.29 -	     (Timidity_Init(mixer->freq, mixer->format,
    1.30 -	                    mixer->channels, mixer->samples) != 0) ) {
    1.31  		timidity_ok = 0;
    1.32  	}
    1.33 +#ifdef USE_NATIVE_MIDI
    1.34 +	native_midi_ok = !timidity_ok;
    1.35 +	if ( native_midi_ok ) {
    1.36 +		native_midi_ok = native_midi_init();
    1.37 +	}
    1.38 +#endif
    1.39  #endif
    1.40  #ifdef OGG_MUSIC
    1.41  	if ( OGG_init(mixer) < 0 ) {