blob: dcf28410a17fca9ae2f6ce751f7dba0a94850839 [file] [log] [blame]
niklase@google.com470e71d2011-07-07 08:21:25 +00001/*
leozwang@webrtc.org0975d212012-03-06 20:59:13 +00002 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
niklase@google.com470e71d2011-07-07 08:21:25 +00003 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
11#ifndef WEBRTC_VOICE_ENGINE_VOE_RTP_RTCP_IMPL_H
12#define WEBRTC_VOICE_ENGINE_VOE_RTP_RTCP_IMPL_H
13
pbos@webrtc.org956aa7e2013-05-21 13:52:32 +000014#include "webrtc/voice_engine/include/voe_rtp_rtcp.h"
niklase@google.com470e71d2011-07-07 08:21:25 +000015
pbos@webrtc.org956aa7e2013-05-21 13:52:32 +000016#include "webrtc/voice_engine/shared_data.h"
niklase@google.com470e71d2011-07-07 08:21:25 +000017
18namespace webrtc {
19
Jelena Marusic0d266052015-05-04 14:15:32 +020020class VoERTP_RTCPImpl : public VoERTP_RTCP {
21 public:
22 // RTCP
23 int SetRTCPStatus(int channel, bool enable) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000024
Jelena Marusic0d266052015-05-04 14:15:32 +020025 int GetRTCPStatus(int channel, bool& enabled) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000026
Jelena Marusic0d266052015-05-04 14:15:32 +020027 int SetRTCP_CNAME(int channel, const char cName[256]) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000028
Jelena Marusic0d266052015-05-04 14:15:32 +020029 int GetRemoteRTCP_CNAME(int channel, char cName[256]) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000030
Jelena Marusic0d266052015-05-04 14:15:32 +020031 int GetRemoteRTCPData(int channel,
32 unsigned int& NTPHigh,
33 unsigned int& NTPLow,
34 unsigned int& timestamp,
35 unsigned int& playoutTimestamp,
36 unsigned int* jitter = NULL,
37 unsigned short* fractionLost = NULL) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000038
Jelena Marusic0d266052015-05-04 14:15:32 +020039 // SSRC
40 int SetLocalSSRC(int channel, unsigned int ssrc) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000041
Jelena Marusic0d266052015-05-04 14:15:32 +020042 int GetLocalSSRC(int channel, unsigned int& ssrc) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000043
Jelena Marusic0d266052015-05-04 14:15:32 +020044 int GetRemoteSSRC(int channel, unsigned int& ssrc) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000045
Jelena Marusic0d266052015-05-04 14:15:32 +020046 // RTP Header Extension for Client-to-Mixer Audio Level Indication
47 int SetSendAudioLevelIndicationStatus(int channel,
48 bool enable,
49 unsigned char id) override;
50 int SetReceiveAudioLevelIndicationStatus(int channel,
51 bool enable,
52 unsigned char id) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000053
Jelena Marusic0d266052015-05-04 14:15:32 +020054 // Statistics
55 int GetRTPStatistics(int channel,
56 unsigned int& averageJitterMs,
57 unsigned int& maxJitterMs,
58 unsigned int& discardedPackets) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000059
Jelena Marusic0d266052015-05-04 14:15:32 +020060 int GetRTCPStatistics(int channel, CallStatistics& stats) override;
niklase@google.com470e71d2011-07-07 08:21:25 +000061
Jelena Marusic0d266052015-05-04 14:15:32 +020062 int GetRemoteRTCPReportBlocks(
63 int channel,
64 std::vector<ReportBlock>* report_blocks) override;
henrika@webrtc.org8a2fc882012-08-22 08:53:55 +000065
Jelena Marusic0d266052015-05-04 14:15:32 +020066 // NACK
67 int SetNACKStatus(int channel, bool enable, int maxNoPackets) override;
niklas.enbom@webrtc.orgb35d2e32013-05-31 21:13:52 +000068
Jelena Marusic0d266052015-05-04 14:15:32 +020069 protected:
70 VoERTP_RTCPImpl(voe::SharedData* shared);
71 ~VoERTP_RTCPImpl() override;
72
73 private:
74 voe::SharedData* _shared;
niklase@google.com470e71d2011-07-07 08:21:25 +000075};
76
77} // namespace webrtc
78
Jelena Marusic0d266052015-05-04 14:15:32 +020079#endif // WEBRTC_VOICE_ENGINE_VOE_RTP_RTCP_IMPL_H