Mercurial > hg > dmlib
comparison tools/ppl.c @ 2089:dcca36701cdd
Cleanups.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Tue, 19 Feb 2019 12:18:12 +0200 |
parents | 3a768f8d409d |
children | e0281dae2cb8 |
comparison
equal
deleted
inserted
replaced
2088:e900e6e2593d | 2089:dcca36701cdd |
---|---|
525 } | 525 } |
526 | 526 |
527 | 527 |
528 void dmMuteChannels(BOOL mute) | 528 void dmMuteChannels(BOOL mute) |
529 { | 529 { |
530 int i; | 530 for (int i = 0; i < eng.mod->nchannels; i++) |
531 for (i = 0; i < eng.mod->nchannels; i++) | |
532 jvmMute(eng.dev, i, mute); | 531 jvmMute(eng.dev, i, mute); |
533 } | 532 } |
534 | 533 |
535 | 534 |
536 int main(int argc, char *argv[]) | 535 int main(int argc, char *argv[]) |
919 | 918 |
920 SDL_Delay(eng.pauseFlag ? 100 : 30); | 919 SDL_Delay(eng.pauseFlag ? 100 : 30); |
921 } | 920 } |
922 | 921 |
923 error_exit: | 922 error_exit: |
924 if (eng.texture != NULL) | 923 SDL_DestroyTexture(eng.texture); |
925 SDL_DestroyTexture(eng.texture); | 924 SDL_DestroyRenderer(eng.renderer); |
926 | 925 SDL_DestroyWindow(eng.window); |
927 if (eng.renderer != NULL) | 926 SDL_FreeSurface(eng.screen); |
928 SDL_DestroyRenderer(eng.renderer); | |
929 | |
930 if (eng.window != NULL) | |
931 SDL_DestroyWindow(eng.window); | |
932 | |
933 if (eng.screen != NULL) | |
934 SDL_FreeSurface(eng.screen); | |
935 | 927 |
936 dmMsg(0, "Audio shutdown.\n"); | 928 dmMsg(0, "Audio shutdown.\n"); |
937 if (audioInit) | 929 if (audioInit) |
938 { | 930 { |
939 SDL_LockAudio(); | 931 SDL_LockAudio(); |