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

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

Issue 257323003: Remove the IPC to request DemuxerConfigs when config changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: adding CHECK to enforce the optional demuxer_configs only has 0 or 1 element Created 6 years, 7 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 | Annotate | Revision Log
« 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 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 // Helper function to determine whether a protected surface is needed for 161 // Helper function to determine whether a protected surface is needed for
162 // video playback. 162 // video playback.
163 bool IsProtectedSurfaceRequired(); 163 bool IsProtectedSurfaceRequired();
164 164
165 // Called when a MediaDecoderJob finishes prefetching data. Once all 165 // Called when a MediaDecoderJob finishes prefetching data. Once all
166 // MediaDecoderJobs have prefetched data, then this method updates 166 // MediaDecoderJobs have prefetched data, then this method updates
167 // |start_time_ticks_| and |start_presentation_timestamp_| so that video can 167 // |start_time_ticks_| and |start_presentation_timestamp_| so that video can
168 // resync with audio and starts decoding. 168 // resync with audio and starts decoding.
169 void OnPrefetchDone(); 169 void OnPrefetchDone();
170 170
171 // Sets the demuxer configs for audio or video stream.
172 void SetDemuxerConfigs(const DemuxerConfigs& configs, bool is_audio);
173
171 // Test-only method to setup hook for the completion of the next decode cycle. 174 // Test-only method to setup hook for the completion of the next decode cycle.
172 // This callback state is cleared when it is next run. 175 // This callback state is cleared when it is next run.
173 // Prevent usage creep by only calling this from the 176 // Prevent usage creep by only calling this from the
174 // ReleaseWithOnPrefetchDoneAlreadyPosted MediaSourcePlayerTest. 177 // ReleaseWithOnPrefetchDoneAlreadyPosted MediaSourcePlayerTest.
175 void set_decode_callback_for_testing(const base::Closure& test_decode_cb) { 178 void set_decode_callback_for_testing(const base::Closure& test_decode_cb) {
176 decode_callback_for_testing_ = test_decode_cb; 179 decode_callback_for_testing_ = test_decode_cb;
177 } 180 }
178 181
179 // TODO(qinmin/wolenetz): Reorder these based on their priority from 182 // TODO(qinmin/wolenetz): Reorder these based on their priority from
180 // ProcessPendingEvents(). Release() and other routines are dependent upon 183 // ProcessPendingEvents(). Release() and other routines are dependent upon
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 // Weak pointer passed to media decoder jobs for callbacks. 292 // Weak pointer passed to media decoder jobs for callbacks.
290 // NOTE: Weak pointers must be invalidated before all other member variables. 293 // NOTE: Weak pointers must be invalidated before all other member variables.
291 base::WeakPtrFactory<MediaSourcePlayer> weak_factory_; 294 base::WeakPtrFactory<MediaSourcePlayer> weak_factory_;
292 295
293 DISALLOW_COPY_AND_ASSIGN(MediaSourcePlayer); 296 DISALLOW_COPY_AND_ASSIGN(MediaSourcePlayer);
294 }; 297 };
295 298
296 } // namespace media 299 } // namespace media
297 300
298 #endif // MEDIA_BASE_ANDROID_MEDIA_SOURCE_PLAYER_H_ 301 #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