Commit f3d677fb authored by Guillaume Roguez's avatar Guillaume Roguez Committed by gerrit2

coreaudio: modern C++

- replace malloc by C++ vector or new[]
- use unique_ptr for dynamic allocations
- use C++ cast than C cast
- do not copy, use const&, & or move-idiom
- replace NULL by nullptr
- AAA rule
- general coding rules

Change-Id: I8a62ca9ef59b0807d5abeb0a5090521843dbb9ca
parent 72ee06ef
This diff is collapsed.
......@@ -162,7 +162,8 @@ class CoreLayer : public AudioLayer {
/** Non-interleaved audio buffers */
AudioBuffer playbackBuff_;
::AudioBufferList* captureBuff_; // CoreAudio buffer.
::AudioBufferList* captureBuff_ {nullptr}; // CoreAudio buffer (pointer is casted rawBuff_)
std::unique_ptr<Byte[]> rawBuff_; // raw allocation of captureBuff_
/** Interleaved buffer */
std::vector<AudioSample> playbackIBuff_;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment