OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MEDIA_CAST_RTP_RECEIVER_RTP_RECEIVER_DEFINES_H_ | 5 #ifndef MEDIA_CAST_RTP_RECEIVER_RTP_RECEIVER_DEFINES_H_ |
6 #define MEDIA_CAST_RTP_RECEIVER_RTP_RECEIVER_DEFINES_H_ | 6 #define MEDIA_CAST_RTP_RECEIVER_RTP_RECEIVER_DEFINES_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "media/cast/cast_config.h" | 9 #include "media/cast/cast_config.h" |
10 #include "media/cast/rtcp/rtcp_defines.h" | 10 #include "media/cast/rtcp/rtcp_defines.h" |
11 #include "third_party/webrtc/modules/interface/module_common_types.h" | |
12 | 11 |
13 namespace media { | 12 namespace media { |
14 namespace cast { | 13 namespace cast { |
15 | 14 |
16 struct RtpCastHeader { | 15 struct RtpCastHeader { |
17 RtpCastHeader() { | 16 RtpCastHeader(); |
18 is_key_frame = false; | 17 |
19 frame_id = 0; | 18 // Elements from RTP packet header. |
20 packet_id = 0; | 19 bool marker; |
21 max_packet_id = 0; | 20 uint8 payload_type; |
22 is_reference = false; | 21 uint16 sequence_number; |
23 reference_frame_id = 0; | 22 uint32 rtp_timestamp; |
24 } | 23 uint32 sender_ssrc; |
25 webrtc::WebRtcRTPHeader webrtc; | 24 |
25 // Elements from Cast header (at beginning of RTP payload). | |
26 bool is_key_frame; | 26 bool is_key_frame; |
27 uint32 frame_id; | 27 uint32 frame_id; |
28 uint16 packet_id; | 28 uint16 packet_id; |
29 uint16 max_packet_id; | 29 uint16 max_packet_id; |
30 bool is_reference; // Set to true if the previous frame is not available, | |
miu
2014/04/23 23:41:58
I removed this because it is solely a detail of th
| |
31 // and the reference frame id is available. | |
32 uint32 reference_frame_id; | 30 uint32 reference_frame_id; |
33 }; | 31 }; |
34 | 32 |
35 class RtpPayloadFeedback { | 33 class RtpPayloadFeedback { |
36 public: | 34 public: |
37 virtual void CastFeedback(const RtcpCastMessage& cast_feedback) = 0; | 35 virtual void CastFeedback(const RtcpCastMessage& cast_feedback) = 0; |
38 | 36 |
39 protected: | 37 protected: |
40 virtual ~RtpPayloadFeedback() {} | 38 virtual ~RtpPayloadFeedback(); |
41 }; | 39 }; |
42 | 40 |
43 } // namespace cast | 41 } // namespace cast |
44 } // namespace media | 42 } // namespace media |
45 | 43 |
46 #endif // MEDIA_CAST_RTP_RECEIVER_RTP_RECEIVER_DEFINES_H_ | 44 #endif // MEDIA_CAST_RTP_RECEIVER_RTP_RECEIVER_DEFINES_H_ |
OLD | NEW |