Deprecated SetAudioPacketSize from RTPSender and removed calls to it.

The packet size was only used to control how often to output DTMF
packets. However, it likely did not work as intended, since that
interval was only set during initialization. No changes to the packet
size, like what AudioEncoder::Num10MsFramesInNextPacket could
indicate, were picked up. The value was instead taken from an entry in
ACMCodecDB.

Since it was not-fully-functional, its exact value didn't seem to
matter and it was getting in the way of making it possible to supply
an external audio encoder factory, I've decided to remove it
altogether. The DTMF code now uses an interval of 50 ms regardless,
which is a value recommended by the RFC.

BUG=webrtc:5806

Review-Url: https://codereview.webrtc.org/2545753002
Cr-Commit-Position: refs/heads/master@{#15380}
This commit is contained in:
ossu
2016-12-02 02:40:02 -08:00
committed by Commit bot
parent e066b302ab
commit 00bceb1eda
8 changed files with 23 additions and 36 deletions

View File

@ -260,8 +260,8 @@ class ModuleRtpRtcpImpl : public RtpRtcp, public RTCPReceiver::ModuleRtpRtcp {
// Audio part.
// Set audio packet size, used to determine when it's time to send a DTMF
// packet in silence (CNG).
// This function is deprecated. It was previously used to determine when it
// was time to send a DTMF packet in silence (CNG).
int32_t SetAudioPacketSize(uint16_t packet_size_samples) override;
// Send a TelephoneEvent tone using RFC 2833 (4733).