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

Side by Side Diff: webrtc/common_audio/audio_ring_buffer.h

Issue 1937693002: Replace scoped_ptr with unique_ptr everywhere (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@unique5
Patch Set: Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « webrtc/base/thread_unittest.cc ('k') | webrtc/common_audio/real_fourier.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 #ifndef WEBRTC_COMMON_AUDIO_AUDIO_RING_BUFFER_H_ 10 #ifndef WEBRTC_COMMON_AUDIO_AUDIO_RING_BUFFER_H_
11 #define WEBRTC_COMMON_AUDIO_AUDIO_RING_BUFFER_H_ 11 #define WEBRTC_COMMON_AUDIO_AUDIO_RING_BUFFER_H_
12 12
13 #include <stddef.h> 13 #include <stddef.h>
14
15 #include <memory>
14 #include <vector> 16 #include <vector>
15 17
16 struct RingBuffer; 18 struct RingBuffer;
17 19
18 namespace webrtc { 20 namespace webrtc {
19 21
20 // A ring buffer tailored for float deinterleaved audio. Any operation that 22 // A ring buffer tailored for float deinterleaved audio. Any operation that
21 // cannot be performed as requested will cause a crash (e.g. insufficient data 23 // cannot be performed as requested will cause a crash (e.g. insufficient data
22 // in the buffer to fulfill a read request.) 24 // in the buffer to fulfill a read request.)
23 class AudioRingBuffer final { 25 class AudioRingBuffer final {
(...skipping 22 matching lines...) Expand all
46 void MoveReadPositionBackward(size_t frames); 48 void MoveReadPositionBackward(size_t frames);
47 49
48 private: 50 private:
49 // TODO(kwiberg): Use std::vector<std::unique_ptr<RingBuffer>> instead. 51 // TODO(kwiberg): Use std::vector<std::unique_ptr<RingBuffer>> instead.
50 std::vector<RingBuffer*> buffers_; 52 std::vector<RingBuffer*> buffers_;
51 }; 53 };
52 54
53 } // namespace webrtc 55 } // namespace webrtc
54 56
55 #endif // WEBRTC_COMMON_AUDIO_AUDIO_RING_BUFFER_H_ 57 #endif // WEBRTC_COMMON_AUDIO_AUDIO_RING_BUFFER_H_
OLDNEW
« no previous file with comments | « webrtc/base/thread_unittest.cc ('k') | webrtc/common_audio/real_fourier.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698