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

Side by Side Diff: media/formats/mpeg/mpeg_audio_stream_parser_base.cc

Issue 784493002: Encrypted Media: Rename NeedKey to EncryptedMediaInitData. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments addressed Created 6 years 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 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 #include "media/formats/mpeg/mpeg_audio_stream_parser_base.h" 5 #include "media/formats/mpeg/mpeg_audio_stream_parser_base.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback_helpers.h" 8 #include "base/callback_helpers.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "media/base/buffers.h" 10 #include "media/base/buffers.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 AudioCodec audio_codec, 47 AudioCodec audio_codec,
48 int codec_delay) 48 int codec_delay)
49 : state_(UNINITIALIZED), 49 : state_(UNINITIALIZED),
50 in_media_segment_(false), 50 in_media_segment_(false),
51 start_code_mask_(start_code_mask), 51 start_code_mask_(start_code_mask),
52 audio_codec_(audio_codec), 52 audio_codec_(audio_codec),
53 codec_delay_(codec_delay) {} 53 codec_delay_(codec_delay) {}
54 54
55 MPEGAudioStreamParserBase::~MPEGAudioStreamParserBase() {} 55 MPEGAudioStreamParserBase::~MPEGAudioStreamParserBase() {}
56 56
57 void MPEGAudioStreamParserBase::Init(const InitCB& init_cb, 57 void MPEGAudioStreamParserBase::Init(
58 const NewConfigCB& config_cb, 58 const InitCB& init_cb,
59 const NewBuffersCB& new_buffers_cb, 59 const NewConfigCB& config_cb,
60 bool ignore_text_tracks, 60 const NewBuffersCB& new_buffers_cb,
61 const NeedKeyCB& need_key_cb, 61 bool ignore_text_tracks,
62 const NewMediaSegmentCB& new_segment_cb, 62 const EncryptedMediaInitDataCB& encrypted_media_init_data_cb,
63 const base::Closure& end_of_segment_cb, 63 const NewMediaSegmentCB& new_segment_cb,
64 const LogCB& log_cb) { 64 const base::Closure& end_of_segment_cb,
65 const LogCB& log_cb) {
65 DVLOG(1) << __FUNCTION__; 66 DVLOG(1) << __FUNCTION__;
66 DCHECK_EQ(state_, UNINITIALIZED); 67 DCHECK_EQ(state_, UNINITIALIZED);
67 init_cb_ = init_cb; 68 init_cb_ = init_cb;
68 config_cb_ = config_cb; 69 config_cb_ = config_cb;
69 new_buffers_cb_ = new_buffers_cb; 70 new_buffers_cb_ = new_buffers_cb;
70 new_segment_cb_ = new_segment_cb; 71 new_segment_cb_ = new_segment_cb;
71 end_of_segment_cb_ = end_of_segment_cb; 72 end_of_segment_cb_ = end_of_segment_cb;
72 log_cb_ = log_cb; 73 log_cb_ = log_cb;
73 74
74 ChangeState(INITIALIZED); 75 ChangeState(INITIALIZED);
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 if (end_of_segment) { 413 if (end_of_segment) {
413 in_media_segment_ = false; 414 in_media_segment_ = false;
414 end_of_segment_cb_.Run(); 415 end_of_segment_cb_.Run();
415 } 416 }
416 417
417 timestamp_helper_->SetBaseTimestamp(base::TimeDelta()); 418 timestamp_helper_->SetBaseTimestamp(base::TimeDelta());
418 return true; 419 return true;
419 } 420 }
420 421
421 } // namespace media 422 } // namespace media
OLDNEW
« no previous file with comments | « media/formats/mpeg/mpeg_audio_stream_parser_base.h ('k') | media/formats/webm/webm_stream_parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698