Mercurial > hg > Game > Cerium
changeset 2024:472528b62bbf draft
fix Make test
author | Masataka Kohagura <kohagura@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Sun, 27 Jul 2014 23:40:37 +0900 |
parents | 8c3c826ba4d5 |
children | f31415b52f51 |
files | example/synthesizer/Makefile example/synthesizer/main.cc |
diffstat | 2 files changed, 6 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/example/synthesizer/Makefile Mon Jul 21 18:49:17 2014 +0900 +++ b/example/synthesizer/Makefile Sun Jul 27 23:40:37 2014 +0900 @@ -21,7 +21,7 @@ @$(MAKE) -f Makefile.cuda test: - ./synthesizer + ./synthesizer -wave tri parallel-test: macosx @$(MAKE) -f Makefile.macosx test
--- a/example/synthesizer/main.cc Mon Jul 21 18:49:17 2014 +0900 +++ b/example/synthesizer/main.cc Sun Jul 27 23:40:37 2014 +0900 @@ -24,9 +24,9 @@ CPU_TYPE spe_cpu = SPE_ANY; int volume = 3000; double frequency = 440; -char *waveform_name = "tri"; +char *waveform_name; -const char *usr_help_str = "Usage: ./synthesizer [-freq freqency] [-wave \"sqr\" or \"tri\"] [-vol volume]\n"; +const char *usr_help_str = "Usage: ./synthesizer -wave \"sqr\" or \"tri\" [-freq freqency] [-vol volume]"; static void run_start(TaskManager *manager) @@ -69,12 +69,9 @@ TMmain(TaskManager *manager, int argc, char *argv[]) { init(argc, argv); - if(argc == 1) { - printf("%s",usr_help_str); - printf("Default settings\n"); - printf("frequency :%fHz(A)\n",frequency); - printf("wave :%s\n",waveform_name); - printf("Volume :%d\n",volume); + if(waveform_name == 0) { + puts(usr_help_str); + exit(1); } task_init();