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

Side by Side Diff: media/base/android/media_source_player.h

Issue 23620012: Fix MediaSourcePlayer unittests and minor code cleanup. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix bug introduced by code in the rebase. Created 7 years, 3 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 | « media/base/android/media_decoder_job.cc ('k') | media/base/android/media_source_player.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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_
6 #define MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ 6 #define MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 bool HasVideo(); 110 bool HasVideo();
111 bool HasAudio(); 111 bool HasAudio();
112 112
113 // Determine seekability based on duration. 113 // Determine seekability based on duration.
114 bool Seekable(); 114 bool Seekable();
115 115
116 // Called when the |decoder_starvation_callback_| times out. 116 // Called when the |decoder_starvation_callback_| times out.
117 void OnDecoderStarved(); 117 void OnDecoderStarved();
118 118
119 // Starts the |decoder_starvation_callback_| task with the timeout value. 119 // Starts the |decoder_starvation_callback_| task with the timeout value.
120 void StartStarvationCallback(const base::TimeDelta& timeout); 120 // |presentation_timestamp| - The presentation timestamp used for starvation
121 // timeout computations. It represents the timestamp of the last piece of
122 // decoded data.
123 void StartStarvationCallback(const base::TimeDelta& presentation_timestamp);
121 124
122 // Schedules a seek event in |pending_events_| and calls StopDecode() on all 125 // Schedules a seek event in |pending_events_| and calls StopDecode() on all
123 // the MediaDecoderJobs. 126 // the MediaDecoderJobs.
124 void ScheduleSeekEventAndStopDecoding(); 127 void ScheduleSeekEventAndStopDecoding();
125 128
126 // Helper function to set the volume. 129 // Helper function to set the volume.
127 void SetVolumeInternal(); 130 void SetVolumeInternal();
128 131
129 // Helper function to determine whether a protected surface is needed for 132 // Helper function to determine whether a protected surface is needed for
130 // video playback. 133 // video playback.
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 214
212 MediaDrmBridge* drm_bridge_; 215 MediaDrmBridge* drm_bridge_;
213 216
214 friend class MediaSourcePlayerTest; 217 friend class MediaSourcePlayerTest;
215 DISALLOW_COPY_AND_ASSIGN(MediaSourcePlayer); 218 DISALLOW_COPY_AND_ASSIGN(MediaSourcePlayer);
216 }; 219 };
217 220
218 } // namespace media 221 } // namespace media
219 222
220 #endif // MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ 223 #endif // MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_
OLDNEW
« no previous file with comments | « media/base/android/media_decoder_job.cc ('k') | media/base/android/media_source_player.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698