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

Unified Diff: webrtc/api/java/jni/androidmediaencoder_jni.cc

Issue 1930463002: Replace scoped_ptr with unique_ptr in webrtc/api/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.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 | « webrtc/api/java/jni/androidmediadecoder_jni.cc ('k') | webrtc/api/java/jni/androidvideocapturer_jni.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/api/java/jni/androidmediaencoder_jni.cc
diff --git a/webrtc/api/java/jni/androidmediaencoder_jni.cc b/webrtc/api/java/jni/androidmediaencoder_jni.cc
index e88a94ce7f1de93d928aedf0aba1e3523383c47d..b7f2da475017e8cb794d994e7a280229a80ac8f5 100644
--- a/webrtc/api/java/jni/androidmediaencoder_jni.cc
+++ b/webrtc/api/java/jni/androidmediaencoder_jni.cc
@@ -13,6 +13,7 @@
#include "webrtc/api/java/jni/androidmediaencoder_jni.h"
#include <algorithm>
+#include <memory>
#include <list>
#include "third_party/libyuv/include/libyuv/convert.h"
@@ -37,7 +38,6 @@
using rtc::Bind;
using rtc::Thread;
using rtc::ThreadManager;
-using rtc::scoped_ptr;
using webrtc::CodecSpecificInfo;
using webrtc::EncodedImage;
@@ -182,7 +182,8 @@ class MediaCodecVideoEncoder : public webrtc::VideoEncoder,
// State that is constant for the lifetime of this object once the ctor
// returns.
- scoped_ptr<Thread> codec_thread_; // Thread on which to operate MediaCodec.
+ std::unique_ptr<Thread>
+ codec_thread_; // Thread on which to operate MediaCodec.
rtc::ThreadChecker codec_thread_checker_;
ScopedGlobalRef<jclass> j_media_codec_video_encoder_class_;
ScopedGlobalRef<jobject> j_media_codec_video_encoder_;
@@ -973,7 +974,7 @@ bool MediaCodecVideoEncoder::DeliverPendingOutputs(JNIEnv* jni) {
// Callback - return encoded frame.
int32_t callback_status = 0;
if (callback_) {
- scoped_ptr<webrtc::EncodedImage> image(
+ std::unique_ptr<webrtc::EncodedImage> image(
new webrtc::EncodedImage(payload, payload_size, payload_size));
image->_encodedWidth = width_;
image->_encodedHeight = height_;
« no previous file with comments | « webrtc/api/java/jni/androidmediadecoder_jni.cc ('k') | webrtc/api/java/jni/androidvideocapturer_jni.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698