process effect-automation when bouncing w/processing
This commit is contained in:
parent
8f52bf7d9f
commit
491f3f6e44
@ -177,7 +177,7 @@ class LIBARDOUR_API PluginInsert : public Processor
|
||||
/** details of the match currently being used */
|
||||
Match _match;
|
||||
|
||||
void automation_run (BufferSet& bufs, pframes_t nframes);
|
||||
void automation_run (BufferSet& bufs, framepos_t start, pframes_t nframes);
|
||||
void connect_and_run (BufferSet& bufs, pframes_t nframes, framecnt_t offset, bool with_auto, framepos_t now = 0);
|
||||
|
||||
void create_automatable_parameters ();
|
||||
|
@ -791,6 +791,10 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
|
||||
return _exporting;
|
||||
}
|
||||
|
||||
bool bounce_processing() const {
|
||||
return _bounce_processing_active;
|
||||
}
|
||||
|
||||
/* this is a private enum, but setup_enum_writer() needs it,
|
||||
and i can't find a way to give that function
|
||||
friend access. sigh.
|
||||
@ -928,6 +932,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
|
||||
mutable gint processing_prohibited;
|
||||
process_function_type process_function;
|
||||
process_function_type last_process_function;
|
||||
bool _bounce_processing_active;
|
||||
bool waiting_for_sync_offset;
|
||||
framecnt_t _base_frame_rate;
|
||||
framecnt_t _current_frame_rate; //this includes video pullup offset
|
||||
@ -982,7 +987,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
|
||||
void process_without_events (pframes_t);
|
||||
void process_with_events (pframes_t);
|
||||
void process_audition (pframes_t);
|
||||
int process_export (pframes_t);
|
||||
int process_export (pframes_t);
|
||||
int process_export_fw (pframes_t);
|
||||
|
||||
void block_processing() { g_atomic_int_set (&processing_prohibited, 1); }
|
||||
|
@ -455,13 +455,13 @@ PluginInsert::silence (framecnt_t nframes)
|
||||
}
|
||||
|
||||
void
|
||||
PluginInsert::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/, pframes_t nframes, bool)
|
||||
PluginInsert::run (BufferSet& bufs, framepos_t start_frame, framepos_t /*end_frame*/, pframes_t nframes, bool)
|
||||
{
|
||||
if (_pending_active) {
|
||||
/* run as normal if we are active or moving from inactive to active */
|
||||
|
||||
if (_session.transport_rolling()) {
|
||||
automation_run (bufs, nframes);
|
||||
if (_session.transport_rolling() || _session.bounce_processing()) {
|
||||
automation_run (bufs, start_frame, nframes);
|
||||
} else {
|
||||
connect_and_run (bufs, nframes, 0, false);
|
||||
}
|
||||
@ -538,10 +538,10 @@ PluginInsert::get_parameter (Evoral::Parameter param)
|
||||
}
|
||||
|
||||
void
|
||||
PluginInsert::automation_run (BufferSet& bufs, pframes_t nframes)
|
||||
PluginInsert::automation_run (BufferSet& bufs, framepos_t start, pframes_t nframes)
|
||||
{
|
||||
Evoral::ControlEvent next_event (0, 0.0f);
|
||||
framepos_t now = _session.transport_frame ();
|
||||
framepos_t now = start;
|
||||
framepos_t end = now + nframes;
|
||||
framecnt_t offset = 0;
|
||||
|
||||
|
@ -137,6 +137,7 @@ Session::Session (AudioEngine &eng,
|
||||
: playlists (new SessionPlaylists)
|
||||
, _engine (eng)
|
||||
, process_function (&Session::process_with_events)
|
||||
, _bounce_processing_active (false)
|
||||
, waiting_for_sync_offset (false)
|
||||
, _base_frame_rate (0)
|
||||
, _current_frame_rate (0)
|
||||
@ -4169,6 +4170,8 @@ Session::write_one_track (AudioTrack& track, framepos_t start, framepos_t end,
|
||||
Glib::Threads::Mutex::Lock lm (_engine.process_lock());
|
||||
}
|
||||
|
||||
_bounce_processing_active = true;
|
||||
|
||||
_engine.main_thread()->get_buffers ();
|
||||
|
||||
/* call tree *MUST* hold route_lock */
|
||||
@ -4334,6 +4337,7 @@ Session::write_one_track (AudioTrack& track, framepos_t start, framepos_t end,
|
||||
}
|
||||
}
|
||||
|
||||
_bounce_processing_active = false;
|
||||
|
||||
if (need_block_size_reset) {
|
||||
track.set_block_size (get_block_size());
|
||||
|
Loading…
Reference in New Issue
Block a user