[xiph-cvs] cvs commit: vorbis-tools/oggenc encode.c
Michael Smith
msmith at xiph.org
Mon Jul 1 04:44:03 PDT 2002
msmith 02/07/01 04:44:03
Modified: oggenc encode.c
Log:
Support for setting lowpass frequency and impulse threshold in oggenc
Revision Changes Path
1.24 +19 -7 vorbis-tools/oggenc/encode.c
Index: encode.c
===================================================================
RCS file: /usr/local/cvsroot/vorbis-tools/oggenc/encode.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- encode.c 2002/06/30 13:39:56 1.23
+++ encode.c 2002/07/01 11:44:02 1.24
@@ -59,33 +59,45 @@
fprintf(stderr, _("Setting advanced encoder option \"%s\" to %s\n"),
opts[i].arg, opts[i].val);
- if(!strcmp(opts[i].arg, "average_bitrate_window")) {
+ if(!strcmp(opts[i].arg, "bitrate_average_window")) {
SETD(ai.bitrate_av_window);
avg = 1;
}
- else if(!strcmp(opts[i].arg, "average_bitrate_window_center")) {
+ else if(!strcmp(opts[i].arg, "bitrate_average_window_center")) {
SETD(ai.bitrate_av_window_center);
avg = 1;
}
- else if(!strcmp(opts[i].arg, "average_bitrate_low")) {
+ else if(!strcmp(opts[i].arg, "bitrate_average_low")) {
SETL(ai.bitrate_av_lo);
avg = 1;
}
- else if(!strcmp(opts[i].arg, "average_bitrate_high")) {
+ else if(!strcmp(opts[i].arg, "bitrate_average_high")) {
SETL(ai.bitrate_av_hi);
avg = 1;
}
- else if(!strcmp(opts[i].arg, "hard_bitrate_min")) {
+ else if(!strcmp(opts[i].arg, "bitrate_hard_min")) {
SETL(ai.bitrate_hard_min);
hard = 1;
}
- else if(!strcmp(opts[i].arg, "hard_bitrate_max")) {
+ else if(!strcmp(opts[i].arg, "bitrate_hard_max")) {
SETL(ai.bitrate_hard_max);
hard = 1;
}
- else if(!strcmp(opts[i].arg, "hard_bitrate_window")) {
+ else if(!strcmp(opts[i].arg, "bitrate_hard_window")) {
SETD(ai.bitrate_hard_window);
hard = 1;
+ }
+ else if(!strcmp(opts[i].arg, "impulse_noisetune")) {
+ double val;
+ SETD(val);
+ vorbis_encode_ctl(vi, OV_ECTL_IBLOCK_SET, &val);
+ }
+ else if(!strcmp(opts[i].arg, "lowpass_frequency")) {
+ double prev, new;
+ SETD(new);
+ vorbis_encode_ctl(vi, OV_ECTL_LOWPASS_GET, &prev);
+ vorbis_encode_ctl(vi, OV_ECTL_LOWPASS_SET, &new);
+ fprintf(stderr, _("Changed lowpass frequency from %f kHz to %f kHz\n"), prev, new);
}
else {
fprintf(stderr, _("Unrecognised advanced option \"%s\"\n"),
<p><p><p>--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the commits
mailing list