| Index: media/formats/webm/opus_packet_builder.cc
|
| diff --git a/media/formats/webm/opus_packet_builder.cc b/media/formats/webm/opus_packet_builder.cc
|
| index bd85c3c5215afb084ef3bf9f85085688781ffa63..aa5fa7ad15a46cc868198a751e8752cf7f964d7e 100644
|
| --- a/media/formats/webm/opus_packet_builder.cc
|
| +++ b/media/formats/webm/opus_packet_builder.cc
|
| @@ -2,8 +2,10 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#include "base/logging.h"
|
| #include "media/formats/webm/opus_packet_builder.h"
|
| +
|
| +#include "base/logging.h"
|
| +#include "base/memory/ptr_util.h"
|
| #include "media/formats/webm/webm_cluster_parser.h"
|
|
|
| namespace media {
|
| @@ -62,8 +64,8 @@ double OpusPacket::duration_ms() const {
|
| return duration_ms_;
|
| }
|
|
|
| -ScopedVector<OpusPacket> BuildAllOpusPackets() {
|
| - ScopedVector<OpusPacket> opus_packets;
|
| +std::vector<std::unique_ptr<OpusPacket>> BuildAllOpusPackets() {
|
| + std::vector<std::unique_ptr<OpusPacket>> opus_packets;
|
|
|
| for (int frame_count = kMinOpusPacketFrameCount;
|
| frame_count <= kMaxOpusPacketFrameCount; frame_count++) {
|
| @@ -71,14 +73,14 @@ ScopedVector<OpusPacket> BuildAllOpusPackets() {
|
| opus_config_num++) {
|
| bool is_VBR = false;
|
| opus_packets.push_back(
|
| - new OpusPacket(opus_config_num, frame_count, is_VBR));
|
| + base::MakeUnique<OpusPacket>(opus_config_num, frame_count, is_VBR));
|
|
|
| if (frame_count >= 2) {
|
| // Add another packet with VBR flag toggled. For frame counts >= 2,
|
| // VBR triggers changes to packet framing.
|
| is_VBR = true;
|
| opus_packets.push_back(
|
| - new OpusPacket(opus_config_num, frame_count, is_VBR));
|
| + base::MakeUnique<OpusPacket>(opus_config_num, frame_count, is_VBR));
|
| }
|
| }
|
| }
|
|
|