mirror of https://github.com/ericonr/sndio.git
make default rate a macro instead of using hardcoded 44100
This commit is contained in:
parent
1abacc230b
commit
6b391a082b
|
@ -60,6 +60,13 @@
|
||||||
#define PROG_AUCAT "aucat"
|
#define PROG_AUCAT "aucat"
|
||||||
#define PROG_MIDICAT "midicat"
|
#define PROG_MIDICAT "midicat"
|
||||||
|
|
||||||
|
/*
|
||||||
|
* sample rate if no ``-r'' is used
|
||||||
|
*/
|
||||||
|
#ifndef DEFAULT_RATE
|
||||||
|
#define DEFAULT_RATE 44100
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
int debug_level = 0;
|
int debug_level = 0;
|
||||||
#endif
|
#endif
|
||||||
|
@ -453,8 +460,8 @@ aucat_main(int argc, char **argv)
|
||||||
perror("malloc");
|
perror("malloc");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
aparams_init(&cs->ipar, 0, 1, 44100);
|
aparams_init(&cs->ipar, 0, 1, DEFAULT_RATE);
|
||||||
aparams_init(&cs->opar, 0, 1, 44100);
|
aparams_init(&cs->opar, 0, 1, DEFAULT_RATE);
|
||||||
cs->mmc = 0;
|
cs->mmc = 0;
|
||||||
cs->hdr = HDR_AUTO;
|
cs->hdr = HDR_AUTO;
|
||||||
cs->xrun = XRUN_IGNORE;
|
cs->xrun = XRUN_IGNORE;
|
||||||
|
@ -470,8 +477,8 @@ aucat_main(int argc, char **argv)
|
||||||
perror("malloc");
|
perror("malloc");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
aparams_init(&cd->ipar, 0, 1, 44100);
|
aparams_init(&cd->ipar, 0, 1, DEFAULT_RATE);
|
||||||
aparams_init(&cd->opar, 0, 1, 44100);
|
aparams_init(&cd->opar, 0, 1, DEFAULT_RATE);
|
||||||
SLIST_INIT(&cd->ins);
|
SLIST_INIT(&cd->ins);
|
||||||
SLIST_INIT(&cd->outs);
|
SLIST_INIT(&cd->outs);
|
||||||
SLIST_INIT(&cd->opts);
|
SLIST_INIT(&cd->opts);
|
||||||
|
|
Loading…
Reference in New Issue