diff options
author | Jean-Marc Valin <jean-marc.valin@usherbrooke.ca> | 2008-02-21 16:39:25 +0300 |
---|---|---|
committer | Jean-Marc Valin <jean-marc.valin@usherbrooke.ca> | 2008-02-21 16:39:25 +0300 |
commit | 44ffd5a8daf0bf0e9ee48b181d64f3ed7a008df5 (patch) | |
tree | be5d1fb487c14e505c6f3f97971e01c90d4d6415 /tools | |
parent | 14f5e7cd09ca4728d394ddc78bdc03abb55ba06e (diff) |
Making sure freed or corrupted modes can't be used (produce a run-time warning).
Diffstat (limited to 'tools')
-rw-r--r-- | tools/celtenc.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/celtenc.c b/tools/celtenc.c index 9b7240b..feb7da3 100644 --- a/tools/celtenc.c +++ b/tools/celtenc.c @@ -221,6 +221,7 @@ void usage() printf (" -V Verbose mode (show bit-rate)\n"); printf ("Raw input options:\n"); printf (" --rate n Sampling rate for raw input\n"); + printf (" --mono Consider raw input as mono\n"); printf (" --stereo Consider raw input as stereo\n"); printf (" --le Raw input is little-endian\n"); printf (" --be Raw input is big-endian\n"); @@ -255,6 +256,7 @@ int main(int argc, char **argv) {"be", no_argument, NULL, 0}, {"8bit", no_argument, NULL, 0}, {"16bit", no_argument, NULL, 0}, + {"mono", no_argument, NULL, 0}, {"stereo", no_argument, NULL, 0}, {"rate", required_argument, NULL, 0}, {"version", no_argument, NULL, 0}, @@ -339,7 +341,9 @@ int main(int argc, char **argv) } else if (strcmp(long_options[option_index].name,"stereo")==0) { chan=2; - mode = celt_stereo; + } else if (strcmp(long_options[option_index].name,"mono")==0) + { + chan=1; } else if (strcmp(long_options[option_index].name,"rate")==0) { rate=atoi (optarg); |