| 153 | } |
| 154 | |
| 155 | BufferRef BufferRecorderNode::getRecordedCopy() const |
| 156 | { |
| 157 | // first grab the number of current frames, which may be increasing as the recording continues. |
| 158 | size_t numFrames = mWritePos; |
| 159 | mCopiedBuffer->setSize( numFrames, mRecorderBuffer.getNumChannels() ); |
| 160 | |
| 161 | mCopiedBuffer->copy( mRecorderBuffer, numFrames ); |
| 162 | return mCopiedBuffer; |
| 163 | } |
| 164 | |
| 165 | void BufferRecorderNode::writeToFile( const fs::path &filePath, SampleType sampleType ) |
| 166 | { |