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

Side by Side Diff: media/base/android/media_source_player_unittest.cc

Issue 545993002: Provide fine grained media playback time thru interpolation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase again Created 6 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_source_player.cc ('k') | media/media.gyp » ('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 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 #include <string> 5 #include <string>
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 virtual ~MockMediaPlayerManager() {} 49 virtual ~MockMediaPlayerManager() {}
50 50
51 // MediaPlayerManager implementation. 51 // MediaPlayerManager implementation.
52 virtual MediaResourceGetter* GetMediaResourceGetter() OVERRIDE { 52 virtual MediaResourceGetter* GetMediaResourceGetter() OVERRIDE {
53 return NULL; 53 return NULL;
54 } 54 }
55 virtual MediaUrlInterceptor* GetMediaUrlInterceptor() OVERRIDE { 55 virtual MediaUrlInterceptor* GetMediaUrlInterceptor() OVERRIDE {
56 return NULL; 56 return NULL;
57 } 57 }
58 virtual void OnTimeUpdate(int player_id, 58 virtual void OnTimeUpdate(int player_id,
59 base::TimeDelta current_time) OVERRIDE { 59 base::TimeDelta current_time,
60 base::TimeTicks current_time_ticks) OVERRIDE {
60 timestamp_updated_ = true; 61 timestamp_updated_ = true;
61 } 62 }
62 virtual void OnMediaMetadataChanged( 63 virtual void OnMediaMetadataChanged(
63 int player_id, base::TimeDelta duration, int width, int height, 64 int player_id, base::TimeDelta duration, int width, int height,
64 bool success) OVERRIDE {} 65 bool success) OVERRIDE {}
65 virtual void OnPlaybackComplete(int player_id) OVERRIDE { 66 virtual void OnPlaybackComplete(int player_id) OVERRIDE {
66 playback_completed_ = true; 67 playback_completed_ = true;
67 if (message_loop_->is_running()) 68 if (message_loop_->is_running())
68 message_loop_->Quit(); 69 message_loop_->Quit();
69 } 70 }
(...skipping 2112 matching lines...) Expand 10 before | Expand all | Expand 10 after
2182 2183
2183 DemuxerConfigs configs = CreateAudioDemuxerConfigs(kCodecVorbis, true); 2184 DemuxerConfigs configs = CreateAudioDemuxerConfigs(kCodecVorbis, true);
2184 DemuxerData data = CreateReadFromDemuxerAckWithConfigChanged( 2185 DemuxerData data = CreateReadFromDemuxerAckWithConfigChanged(
2185 true, 0, configs); 2186 true, 0, configs);
2186 player_.OnDemuxerDataAvailable(data); 2187 player_.OnDemuxerDataAvailable(data);
2187 WaitForAudioDecodeDone(); 2188 WaitForAudioDecodeDone();
2188 DecodeAudioDataUntilOutputBecomesAvailable(); 2189 DecodeAudioDataUntilOutputBecomesAvailable();
2189 } 2190 }
2190 2191
2191 } // namespace media 2192 } // namespace media
OLDNEW
« no previous file with comments | « media/base/android/media_source_player.cc ('k') | media/media.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698