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

Unified Diff: media/filters/decrypting_audio_decoder.cc

Issue 17315021: Refactored DataBuffer to use unix_hacker style methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed accidental renaming of test cases. Created 7 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: media/filters/decrypting_audio_decoder.cc
diff --git a/media/filters/decrypting_audio_decoder.cc b/media/filters/decrypting_audio_decoder.cc
index 8aee1411ef7336aef8e871da8fe917d2ee16680c..297e03fd97e20bcc30c976be8e2dd2d40955a38c 100644
--- a/media/filters/decrypting_audio_decoder.cc
+++ b/media/filters/decrypting_audio_decoder.cc
@@ -458,20 +458,20 @@ void DecryptingAudioDecoder::EnqueueFrames(
++iter) {
scoped_refptr<DataBuffer>& frame = *iter;
- DCHECK(!frame->IsEndOfStream()) << "EOS frame returned.";
- DCHECK_GT(frame->GetDataSize(), 0) << "Empty frame returned.";
+ DCHECK(!frame->end_of_stream()) << "EOS frame returned.";
+ DCHECK_GT(frame->data_size(), 0) << "Empty frame returned.";
base::TimeDelta cur_timestamp = output_timestamp_base_ +
NumberOfSamplesToDuration(total_samples_decoded_);
- if (IsOutOfSync(cur_timestamp, frame->GetTimestamp())) {
+ if (IsOutOfSync(cur_timestamp, frame->timestamp())) {
DVLOG(1) << "Timestamp returned by the decoder ("
- << frame->GetTimestamp().InMilliseconds() << " ms)"
+ << frame->timestamp().InMilliseconds() << " ms)"
<< " does not match the input timestamp and number of samples"
<< " decoded (" << cur_timestamp.InMilliseconds() << " ms).";
}
- frame->SetTimestamp(cur_timestamp);
+ frame->set_timestamp(cur_timestamp);
- int frame_size = frame->GetDataSize();
+ int frame_size = frame->data_size();
DCHECK_EQ(frame_size % bytes_per_sample_, 0) <<
"Decoder didn't output full samples";
int samples_decoded = frame_size / bytes_per_sample_;
@@ -480,7 +480,7 @@ void DecryptingAudioDecoder::EnqueueFrames(
base::TimeDelta next_timestamp = output_timestamp_base_ +
NumberOfSamplesToDuration(total_samples_decoded_);
base::TimeDelta duration = next_timestamp - cur_timestamp;
- frame->SetDuration(duration);
+ frame->set_duration(duration);
}
}

Powered by Google App Engine
This is Rietveld 408576698