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

Unified Diff: media/base/simd/convert_rgb_to_yuv_unittest.cc

Issue 1906423005: Replace scoped_ptr with std::unique_ptr in //media/base. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptr-media-base: . 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
Index: media/base/simd/convert_rgb_to_yuv_unittest.cc
diff --git a/media/base/simd/convert_rgb_to_yuv_unittest.cc b/media/base/simd/convert_rgb_to_yuv_unittest.cc
index b5ea88d76dc1cdecb86ca246a08f9ae1e1bdf501..d10de30bebef1c59aeaec9295658f7eacbf76fde 100644
--- a/media/base/simd/convert_rgb_to_yuv_unittest.cc
+++ b/media/base/simd/convert_rgb_to_yuv_unittest.cc
@@ -2,11 +2,13 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "media/base/simd/convert_rgb_to_yuv.h"
+
#include <stdint.h>
+#include <memory>
+
#include "base/cpu.h"
-#include "base/memory/scoped_ptr.h"
-#include "media/base/simd/convert_rgb_to_yuv.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace {
@@ -58,10 +60,10 @@ TEST(YUVConvertTest, MAYBE_SideBySideRGB) {
for (int size = 3; size <= 4; ++size) {
// Create the output buffers.
- scoped_ptr<uint8_t[]> rgb(new uint8_t[kWidth * size]);
- scoped_ptr<uint8_t[]> y(new uint8_t[kWidth]);
- scoped_ptr<uint8_t[]> u(new uint8_t[kWidth / 2]);
- scoped_ptr<uint8_t[]> v(new uint8_t[kWidth / 2]);
+ std::unique_ptr<uint8_t[]> rgb(new uint8_t[kWidth * size]);
+ std::unique_ptr<uint8_t[]> y(new uint8_t[kWidth]);
+ std::unique_ptr<uint8_t[]> u(new uint8_t[kWidth / 2]);
+ std::unique_ptr<uint8_t[]> v(new uint8_t[kWidth / 2]);
// Choose the function that converts from RGB pixels to YUV ones.
void (*convert)(const uint8_t*, uint8_t*, uint8_t*, uint8_t*, int, int, int,

Powered by Google App Engine
This is Rietveld 408576698