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

Side by Side Diff: chromecast/media/cma/base/buffering_controller.h

Issue 652353003: Chromecast: adds class to help record complex histograms. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: resets initial buffering state on flush Created 6 years, 2 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 unified diff | Download patch
« no previous file with comments | « chromecast/chromecast.gyp ('k') | chromecast/media/cma/base/buffering_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CHROMECAST_MEDIA_CMA_BASE_BUFFERING_CONTROLLER_H 5 #ifndef CHROMECAST_MEDIA_CMA_BASE_BUFFERING_CONTROLLER_H
6 #define CHROMECAST_MEDIA_CMA_BASE_BUFFERING_CONTROLLER_H 6 #define CHROMECAST_MEDIA_CMA_BASE_BUFFERING_CONTROLLER_H
7 7
8 #include <list> 8 #include <list>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 scoped_refptr<BufferingConfig> config_; 84 scoped_refptr<BufferingConfig> config_;
85 85
86 // Callback invoked each time there is a change of the buffering state. 86 // Callback invoked each time there is a change of the buffering state.
87 BufferingNotificationCB buffering_notification_cb_; 87 BufferingNotificationCB buffering_notification_cb_;
88 88
89 // State of the buffering controller. 89 // State of the buffering controller.
90 bool is_buffering_; 90 bool is_buffering_;
91 91
92 // Start time of a re-buffering phase. 92 // Start time of a re-buffering phase.
93 base::Time begin_buffering_time_; 93 base::Time begin_buffering_time_;
94 bool initial_buffering_;
94 95
95 // Buffering level for each individual stream. 96 // Buffering level for each individual stream.
96 typedef std::list<scoped_refptr<BufferingState> > StreamList; 97 typedef std::list<scoped_refptr<BufferingState> > StreamList;
97 StreamList stream_list_; 98 StreamList stream_list_;
98 99
99 base::WeakPtr<BufferingController> weak_this_; 100 base::WeakPtr<BufferingController> weak_this_;
100 base::WeakPtrFactory<BufferingController> weak_factory_; 101 base::WeakPtrFactory<BufferingController> weak_factory_;
101 102
102 DISALLOW_COPY_AND_ASSIGN(BufferingController); 103 DISALLOW_COPY_AND_ASSIGN(BufferingController);
103 }; 104 };
104 105
105 } // namespace media 106 } // namespace media
106 } // namespace chromecast 107 } // namespace chromecast
107 108
108 #endif // CHROMECAST_MEDIA_CMA_BASE_BUFFERING_CONTROLLER_H 109 #endif // CHROMECAST_MEDIA_CMA_BASE_BUFFERING_CONTROLLER_H
OLDNEW
« no previous file with comments | « chromecast/chromecast.gyp ('k') | chromecast/media/cma/base/buffering_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698