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

Unified Diff: media/base/demuxer_perftest.cc

Issue 2158923004: Convert media constants to constexpr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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/base/demuxer_perftest.cc
diff --git a/media/base/demuxer_perftest.cc b/media/base/demuxer_perftest.cc
index 06e804eb26729f48e1d7f610175d11347a13b706..8528d3ae5ee7aa4d7658284e6d1b6192e4fda35a 100644
--- a/media/base/demuxer_perftest.cc
+++ b/media/base/demuxer_perftest.cc
@@ -105,7 +105,7 @@ StreamReader::StreamReader(media::Demuxer* demuxer,
if (stream) {
streams_.push_back(stream);
end_of_stream_.push_back(false);
- last_read_timestamp_.push_back(media::kNoTimestamp());
+ last_read_timestamp_.push_back(media::kNoTimestamp);
counts_.push_back(0);
}
@@ -113,7 +113,7 @@ StreamReader::StreamReader(media::Demuxer* demuxer,
if (stream) {
streams_.push_back(stream);
end_of_stream_.push_back(false);
- last_read_timestamp_.push_back(media::kNoTimestamp());
+ last_read_timestamp_.push_back(media::kNoTimestamp);
counts_.push_back(0);
if (enable_bitstream_converter)
@@ -133,7 +133,7 @@ void StreamReader::Read() {
base::MessageLoop::current(), &end_of_stream, &timestamp));
base::RunLoop().Run();
- CHECK(end_of_stream || timestamp != media::kNoTimestamp());
+ CHECK(end_of_stream || timestamp != media::kNoTimestamp);
end_of_stream_[index] = end_of_stream;
last_read_timestamp_[index] = timestamp;
counts_[index]++;
@@ -156,7 +156,7 @@ void StreamReader::OnReadDone(
CHECK_EQ(status, media::DemuxerStream::kOk);
CHECK(buffer.get());
*end_of_stream = buffer->end_of_stream();
- *timestamp = *end_of_stream ? media::kNoTimestamp() : buffer->timestamp();
+ *timestamp = *end_of_stream ? media::kNoTimestamp : buffer->timestamp();
message_loop->task_runner()->PostTask(
FROM_HERE, base::MessageLoop::QuitWhenIdleClosure());
}
@@ -169,7 +169,7 @@ int StreamReader::GetNextStreamIndexToRead() {
continue;
// Use a stream if it hasn't been read from yet.
- if (last_read_timestamp_[i] == media::kNoTimestamp())
+ if (last_read_timestamp_[i] == media::kNoTimestamp)
return i;
if (index < 0 ||

Powered by Google App Engine
This is Rietveld 408576698