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_TRANSPORT_RTP_SENDER_PACKET_STORAGE_PACKET_STORAGE_H_ | 5 #ifndef MEDIA_CAST_NET_RTP_SENDER_PACKET_STORAGE_PACKET_STORAGE_H_ |
6 #define MEDIA_CAST_TRANSPORT_RTP_SENDER_PACKET_STORAGE_PACKET_STORAGE_H_ | 6 #define MEDIA_CAST_NET_RTP_SENDER_PACKET_STORAGE_PACKET_STORAGE_H_ |
7 | 7 |
8 #include <deque> | 8 #include <deque> |
9 #include <list> | 9 #include <list> |
10 #include <map> | 10 #include <map> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/basictypes.h" | 13 #include "base/basictypes.h" |
14 #include "base/memory/linked_ptr.h" | 14 #include "base/memory/linked_ptr.h" |
15 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
16 #include "base/time/tick_clock.h" | 16 #include "base/time/tick_clock.h" |
17 #include "base/time/time.h" | 17 #include "base/time/time.h" |
18 #include "media/cast/transport/cast_transport_config.h" | 18 #include "media/cast/net/cast_transport_config.h" |
19 #include "media/cast/transport/cast_transport_defines.h" | 19 #include "media/cast/net/cast_transport_defines.h" |
20 #include "media/cast/transport/pacing/paced_sender.h" | 20 #include "media/cast/net/pacing/paced_sender.h" |
21 | 21 |
22 namespace media { | 22 namespace media { |
23 namespace cast { | 23 namespace cast { |
24 namespace transport { | |
25 | 24 |
26 // Stores a list of frames. Each frame consists a list of packets. | 25 // Stores a list of frames. Each frame consists a list of packets. |
27 typedef std::deque<SendPacketVector> FrameQueue; | 26 typedef std::deque<SendPacketVector> FrameQueue; |
28 | 27 |
29 class PacketStorage { | 28 class PacketStorage { |
30 public: | 29 public: |
31 explicit PacketStorage(size_t stored_frames); | 30 explicit PacketStorage(size_t stored_frames); |
32 virtual ~PacketStorage(); | 31 virtual ~PacketStorage(); |
33 | 32 |
34 // Returns true if this class is configured correctly. | 33 // Returns true if this class is configured correctly. |
(...skipping 13 matching lines...) Expand all Loading... |
48 | 47 |
49 private: | 48 private: |
50 const size_t max_stored_frames_; | 49 const size_t max_stored_frames_; |
51 FrameQueue frames_; | 50 FrameQueue frames_; |
52 uint32 first_frame_id_in_list_; | 51 uint32 first_frame_id_in_list_; |
53 uint32 last_frame_id_in_list_; | 52 uint32 last_frame_id_in_list_; |
54 | 53 |
55 DISALLOW_COPY_AND_ASSIGN(PacketStorage); | 54 DISALLOW_COPY_AND_ASSIGN(PacketStorage); |
56 }; | 55 }; |
57 | 56 |
58 } // namespace transport | |
59 } // namespace cast | 57 } // namespace cast |
60 } // namespace media | 58 } // namespace media |
61 | 59 |
62 #endif // MEDIA_CAST_TRANSPORT_RTP_SENDER_PACKET_STORAGE_PACKET_STORAGE_H_ | 60 #endif // MEDIA_CAST_NET_RTP_SENDER_PACKET_STORAGE_PACKET_STORAGE_H_ |
OLD | NEW |