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

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

Issue 805273007: Android: Propagate sample rate change to audio decoder job (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
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 #ifndef MEDIA_BASE_ANDROID_MEDIA_DECODER_JOB_H_ 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_DECODER_JOB_H_
6 #define MEDIA_BASE_ANDROID_MEDIA_DECODER_JOB_H_ 6 #define MEDIA_BASE_ANDROID_MEDIA_DECODER_JOB_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 // the decoder job has. 226 // the decoder job has.
227 virtual bool AreDemuxerConfigsChanged( 227 virtual bool AreDemuxerConfigsChanged(
228 const DemuxerConfigs& configs) const = 0; 228 const DemuxerConfigs& configs) const = 0;
229 229
230 // Returns true if |media_codec_bridge_| needs to be reconfigured for the 230 // Returns true if |media_codec_bridge_| needs to be reconfigured for the
231 // new DemuxerConfigs, or false otherwise. 231 // new DemuxerConfigs, or false otherwise.
232 virtual bool IsCodecReconfigureNeeded(const DemuxerConfigs& configs) const; 232 virtual bool IsCodecReconfigureNeeded(const DemuxerConfigs& configs) const;
233 233
234 // Update the output format from the decoder, returns true if the output 234 // Update the output format from the decoder, returns true if the output
235 // format changes, or false otherwise. 235 // format changes, or false otherwise.
236 virtual bool UpdateOutputFormat(); 236 virtual bool UpdateOutputFormat() = 0;
237 237
238 // Return the index to |received_data_| that is not currently being decoded. 238 // Return the index to |received_data_| that is not currently being decoded.
239 size_t inactive_demuxer_data_index() const { 239 size_t inactive_demuxer_data_index() const {
240 return 1 - current_demuxer_data_index_; 240 return 1 - current_demuxer_data_index_;
241 } 241 }
242 242
243 // The UI message loop where callbacks should be dispatched. 243 // The UI message loop where callbacks should be dispatched.
244 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner_; 244 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner_;
245 245
246 // The task runner that decoder job runs on. 246 // The task runner that decoder job runs on.
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
338 // This access unit is passed to the decoder during config changes to drain 338 // This access unit is passed to the decoder during config changes to drain
339 // the decoder. 339 // the decoder.
340 AccessUnit eos_unit_; 340 AccessUnit eos_unit_;
341 341
342 DISALLOW_IMPLICIT_CONSTRUCTORS(MediaDecoderJob); 342 DISALLOW_IMPLICIT_CONSTRUCTORS(MediaDecoderJob);
343 }; 343 };
344 344
345 } // namespace media 345 } // namespace media
346 346
347 #endif // MEDIA_BASE_ANDROID_MEDIA_DECODER_JOB_H_ 347 #endif // MEDIA_BASE_ANDROID_MEDIA_DECODER_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698