OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 virtual ~RtpReceiver() {} | 54 virtual ~RtpReceiver() {} |
55 | 55 |
56 // Returns a TelephoneEventHandler if available. | 56 // Returns a TelephoneEventHandler if available. |
57 virtual TelephoneEventHandler* GetTelephoneEventHandler() = 0; | 57 virtual TelephoneEventHandler* GetTelephoneEventHandler() = 0; |
58 | 58 |
59 // Registers a receive payload in the payload registry and notifies the media | 59 // Registers a receive payload in the payload registry and notifies the media |
60 // receiver strategy. | 60 // receiver strategy. |
61 virtual int32_t RegisterReceivePayload(const CodecInst& audio_codec) = 0; | 61 virtual int32_t RegisterReceivePayload(const CodecInst& audio_codec) = 0; |
62 // Registers a receive payload in the payload registry. | 62 // Registers a receive payload in the payload registry. |
63 virtual int32_t RegisterReceivePayload(const VideoCodec& video_codec) = 0; | 63 virtual int32_t RegisterReceivePayload(const VideoCodec& video_codec) = 0; |
64 // TODO(magjed): Remove once external code is updated. | |
65 virtual int32_t RegisterReceivePayload( | |
66 const char payload_name[RTP_PAYLOAD_NAME_SIZE], | |
67 const int8_t payload_type, | |
68 const uint32_t frequency, | |
69 const size_t channels, | |
70 const uint32_t rate) = 0; | |
71 | 64 |
72 // De-registers |payload_type| from the payload registry. | 65 // De-registers |payload_type| from the payload registry. |
73 virtual int32_t DeRegisterReceivePayload(const int8_t payload_type) = 0; | 66 virtual int32_t DeRegisterReceivePayload(const int8_t payload_type) = 0; |
74 | 67 |
75 // Parses the media specific parts of an RTP packet and updates the receiver | 68 // Parses the media specific parts of an RTP packet and updates the receiver |
76 // state. This for instance means that any changes in SSRC and payload type is | 69 // state. This for instance means that any changes in SSRC and payload type is |
77 // detected and acted upon. | 70 // detected and acted upon. |
78 virtual bool IncomingRtpPacket(const RTPHeader& rtp_header, | 71 virtual bool IncomingRtpPacket(const RTPHeader& rtp_header, |
79 const uint8_t* payload, | 72 const uint8_t* payload, |
80 size_t payload_length, | 73 size_t payload_length, |
(...skipping 12 matching lines...) Expand all Loading... |
93 | 86 |
94 // Returns the current remote CSRCs. | 87 // Returns the current remote CSRCs. |
95 virtual int32_t CSRCs(uint32_t array_of_csrc[kRtpCsrcSize]) const = 0; | 88 virtual int32_t CSRCs(uint32_t array_of_csrc[kRtpCsrcSize]) const = 0; |
96 | 89 |
97 // Returns the current energy of the RTP stream received. | 90 // Returns the current energy of the RTP stream received. |
98 virtual int32_t Energy(uint8_t array_of_energy[kRtpCsrcSize]) const = 0; | 91 virtual int32_t Energy(uint8_t array_of_energy[kRtpCsrcSize]) const = 0; |
99 }; | 92 }; |
100 } // namespace webrtc | 93 } // namespace webrtc |
101 | 94 |
102 #endif // WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_RECEIVER_H_ | 95 #endif // WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_RECEIVER_H_ |
OLD | NEW |