mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-17 20:26:30 +01:00
Allow to dis/engage rec-arm while looping
This commit is contained in:
parent
6bc4f69c5c
commit
ffe7fcd3b0
1 changed files with 11 additions and 0 deletions
|
|
@ -463,6 +463,17 @@ DiskWriter::run (BufferSet& bufs, samplepos_t start_sample, samplepos_t end_samp
|
||||||
*/
|
*/
|
||||||
_capture_captured = start_sample - loop_start;
|
_capture_captured = start_sample - loop_start;
|
||||||
_capture_start_sample = loop_start;
|
_capture_start_sample = loop_start;
|
||||||
|
if (_capture_captured > 0) {
|
||||||
|
/* when enabling record while already looping,
|
||||||
|
* zero fill region back to loop-start.
|
||||||
|
*/
|
||||||
|
for (chan = c->begin(), n = 0; chan != c->end(); ++chan, ++n) {
|
||||||
|
ChannelInfo* chaninfo (*chan);
|
||||||
|
for (samplecnt_t s = 0; s < _capture_captured; ++s) {
|
||||||
|
chaninfo->wbuf->write_one (0); // TODO: optimize
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (_midi_write_source) {
|
if (_midi_write_source) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue