Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(845)

Unified Diff: webrtc/modules/rtp_rtcp/source/rtp_sender_audio.cc

Issue 1803923003: Clean away use of RtpAudioFeedback interface from RTP/RTCP sender code. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebase Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/rtp_rtcp/source/rtp_sender_audio.cc
diff --git a/webrtc/modules/rtp_rtcp/source/rtp_sender_audio.cc b/webrtc/modules/rtp_rtcp/source/rtp_sender_audio.cc
index 2aa4961cdc77d98490c607ed23945617228bf760..804294ac5408547e9e347bd5a743348e9f26dc67 100644
--- a/webrtc/modules/rtp_rtcp/source/rtp_sender_audio.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtp_sender_audio.cc
@@ -21,12 +21,9 @@ namespace webrtc {
static const int kDtmfFrequencyHz = 8000;
-RTPSenderAudio::RTPSenderAudio(Clock* clock,
- RTPSender* rtpSender,
- RtpAudioFeedback* audio_feedback)
+RTPSenderAudio::RTPSenderAudio(Clock* clock, RTPSender* rtpSender)
: _clock(clock),
_rtpSender(rtpSender),
- _audioFeedback(audio_feedback),
_sendAudioCritsect(CriticalSectionWrapper::CreateCriticalSection()),
_packetSizeSamples(160),
_dtmfEventIsOn(false),
@@ -158,7 +155,6 @@ int32_t RTPSenderAudio::SendAudio(FrameType frameType,
// TODO(pwestin) Breakup function in smaller functions.
size_t payloadSize = dataSize;
size_t maxPayloadLength = _rtpSender->MaxPayloadLength();
- bool dtmfToneStarted = false;
uint16_t dtmfLengthMS = 0;
uint8_t key = 0;
int red_payload_type;
@@ -185,15 +181,10 @@ int32_t RTPSenderAudio::SendAudio(FrameType frameType,
_dtmfEventFirstPacketSent = false;
_dtmfKey = key;
_dtmfLengthSamples = (kDtmfFrequencyHz / 1000) * dtmfLengthMS;
- dtmfToneStarted = true;
_dtmfEventIsOn = true;
}
}
}
- if (dtmfToneStarted) {
- if (_audioFeedback)
- _audioFeedback->OnPlayTelephoneEvent(key, dtmfLengthMS, _dtmfLevel);
- }
// A source MAY send events and coded audio packets for the same time
// but we don't support it
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_sender_audio.h ('k') | webrtc/modules/rtp_rtcp/source/rtp_sender_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698