Files
jambonz-infrastructure/packer/jambonz-feature-server/files/mod_opusfile.c.patch
T
2020-03-19 08:16:28 -04:00

14 lines
879 B
Diff

--- mod_opusfile.c 2019-09-25 08:55:37.000000000 -0400
+++ mod_opusfile.c.new 2020-01-02 10:24:57.000000000 -0500
@@ -282,7 +282,9 @@
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "[OGG/OPUS File] Channels: %i\n", head->channel_count);
if (head->input_sample_rate) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "[OGG/OPUS File] Original sampling rate: %lu Hz\n", (unsigned long)head->input_sample_rate);
- handle->samplerate = context->samplerate = head->input_sample_rate;
+ // DH: per https://github.com/xiph/opusfile/blob/d2577d7fdfda04bc32a853e80e62d6faa2a20859/include/opusfile.h#L56
+ // the API always decodes to 48kHz, and we should not be telling freeswitch to play out the originally recorded sample rate
+ // handle->samplerate = context->samplerate = head->input_sample_rate;
}
}
if (op_seekable(context->of)) {