WebRTC Opus C interface: Add support for non-48 kHz decode sample rate
Plus tests for 16 kHz. Bug: webrtc:10631 Change-Id: I2d89bc6d0d9548f0ad7bb1e36d6dfde6b6b31f83 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/138072 Commit-Queue: Karl Wiberg <kwiberg@webrtc.org> Reviewed-by: Minyue Li <minyue@webrtc.org> Cr-Commit-Position: refs/heads/master@{#28099}
This commit is contained in:
@ -328,7 +328,9 @@ int16_t WebRtcOpus_SetBandwidth(OpusEncInst* inst, int32_t bandwidth);
|
||||
*/
|
||||
int16_t WebRtcOpus_SetForceChannels(OpusEncInst* inst, size_t num_channels);
|
||||
|
||||
int16_t WebRtcOpus_DecoderCreate(OpusDecInst** inst, size_t channels);
|
||||
int16_t WebRtcOpus_DecoderCreate(OpusDecInst** inst,
|
||||
size_t channels,
|
||||
int sample_rate_hz);
|
||||
|
||||
/****************************************************************************
|
||||
* WebRtcOpus_MultistreamDecoderCreate(...)
|
||||
@ -488,13 +490,15 @@ int WebRtcOpus_PlcDuration(OpusDecInst* inst);
|
||||
* Input:
|
||||
* - payload : Encoded data pointer
|
||||
* - payload_length_bytes : Bytes of encoded data
|
||||
* - sample_rate_hz : Sample rate of output audio
|
||||
*
|
||||
* Return value : >0 - The duration of the FEC data in the
|
||||
* packet in samples per channel.
|
||||
* 0 - No FEC data in the packet.
|
||||
*/
|
||||
int WebRtcOpus_FecDurationEst(const uint8_t* payload,
|
||||
size_t payload_length_bytes);
|
||||
size_t payload_length_bytes,
|
||||
int sample_rate_hz);
|
||||
|
||||
/****************************************************************************
|
||||
* WebRtcOpus_PacketHasFec(...)
|
||||
|
||||
Reference in New Issue
Block a user