}
}
+/** Ensure we have space for at least a certain number of frames. If we extend
+ * the buffers, fill the new space with silence.
+ */
void
AudioBuffers::ensure_size (int frames)
{
if (!_data[i]) {
throw bad_alloc ();
}
+ for (int j = _allocated_frames; j < frames; ++j) {
+ _data[i][j] = 0;
+ }
}
_allocated_frames = frames;