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

Unified Diff: media/cast/receiver/video_decoder.cc

Issue 1905763002: Convert //media/cast from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « media/cast/receiver/video_decoder.h ('k') | media/cast/receiver/video_decoder_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cast/receiver/video_decoder.cc
diff --git a/media/cast/receiver/video_decoder.cc b/media/cast/receiver/video_decoder.cc
index 7d834f0374cad6ed0101d2977d08975ab4f78c9d..a30bc713415532ab26099231b2a20a0477aa9fd0 100644
--- a/media/cast/receiver/video_decoder.cc
+++ b/media/cast/receiver/video_decoder.cc
@@ -45,7 +45,7 @@ class VideoDecoder::ImplBase
return operational_status_;
}
- void DecodeFrame(scoped_ptr<EncodedFrame> encoded_frame,
+ void DecodeFrame(std::unique_ptr<EncodedFrame> encoded_frame,
const DecodeFrameCallback& callback) {
DCHECK_EQ(operational_status_, STATUS_INITIALIZED);
@@ -69,7 +69,7 @@ class VideoDecoder::ImplBase
decoded_frame->set_timestamp(
encoded_frame->rtp_timestamp.ToTimeDelta(kVideoFrequency));
- scoped_ptr<FrameEvent> decode_event(new FrameEvent());
+ std::unique_ptr<FrameEvent> decode_event(new FrameEvent());
decode_event->timestamp = cast_environment_->Clock()->NowTicks();
decode_event->type = FRAME_DECODED;
decode_event->media_type = VIDEO_EVENT;
@@ -204,7 +204,7 @@ class VideoDecoder::FakeImpl : public VideoDecoder::ImplBase {
if (!len || data[0] != '{')
return NULL;
base::JSONReader reader;
- scoped_ptr<base::Value> values(
+ std::unique_ptr<base::Value> values(
reader.Read(base::StringPiece(reinterpret_cast<char*>(data), len)));
if (!values)
return NULL;
@@ -259,9 +259,8 @@ OperationalStatus VideoDecoder::InitializationResult() const {
return STATUS_UNSUPPORTED_CODEC;
}
-void VideoDecoder::DecodeFrame(
- scoped_ptr<EncodedFrame> encoded_frame,
- const DecodeFrameCallback& callback) {
+void VideoDecoder::DecodeFrame(std::unique_ptr<EncodedFrame> encoded_frame,
+ const DecodeFrameCallback& callback) {
DCHECK(encoded_frame.get());
DCHECK(!callback.is_null());
if (!impl_.get() || impl_->InitializationResult() != STATUS_INITIALIZED) {
« no previous file with comments | « media/cast/receiver/video_decoder.h ('k') | media/cast/receiver/video_decoder_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698