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

Unified Diff: media/formats/mp4/hevc.cc

Issue 1874413003: Convert media/formats 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
Index: media/formats/mp4/hevc.cc
diff --git a/media/formats/mp4/hevc.cc b/media/formats/mp4/hevc.cc
index 0934a9db2675c5955513f6473249dee435c9e9bd..ef47387343fd906a14429b8c7d39e781717d50d0 100644
--- a/media/formats/mp4/hevc.cc
+++ b/media/formats/mp4/hevc.cc
@@ -5,6 +5,7 @@
#include "media/formats/mp4/hevc.h"
#include <algorithm>
+#include <memory>
#include <utility>
#include <vector>
@@ -132,7 +133,7 @@ bool HEVC::InsertParamSetsAnnexB(
std::vector<SubsampleEntry>* subsamples) {
DCHECK(HEVC::IsValidAnnexB(*buffer, *subsamples));
- scoped_ptr<H265Parser> parser(new H265Parser());
+ std::unique_ptr<H265Parser> parser(new H265Parser());
const uint8_t* start = &(*buffer)[0];
parser->SetEncryptedStream(start, buffer->size(), *subsamples);
@@ -212,9 +213,9 @@ bool HEVC::IsValidAnnexB(const uint8_t* buffer,
}
HEVCBitstreamConverter::HEVCBitstreamConverter(
- scoped_ptr<HEVCDecoderConfigurationRecord> hevc_config)
+ std::unique_ptr<HEVCDecoderConfigurationRecord> hevc_config)
: hevc_config_(std::move(hevc_config)) {
- DCHECK(hevc_config_);
+ DCHECK(hevc_config_);
}
HEVCBitstreamConverter::~HEVCBitstreamConverter() {

Powered by Google App Engine
This is Rietveld 408576698