X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Fardour%2Fredirect.h;h=fbbb295a24500e6769dba208ef406ec331890aa9;hb=09d6a963216ded5c47adc911c546fb280b8ac89e;hp=62da98aed1cec5a33a9294ec72b521b9ae822eaa;hpb=30ab1fd61569f9d7fb7410d483fa68cbf9865c37;p=ardour.git diff --git a/libs/ardour/ardour/redirect.h b/libs/ardour/ardour/redirect.h index 62da98aed1..fbbb295a24 100644 --- a/libs/ardour/ardour/redirect.h +++ b/libs/ardour/ardour/redirect.h @@ -15,7 +15,6 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - $Id$ */ #ifndef __ardour_redirect_h__ @@ -47,14 +46,6 @@ namespace ARDOUR { class Session; -struct RedirectState : public StateManager::State { - RedirectState (string why) - : StateManager::State (why) {} - ~RedirectState () {} - - bool active; -}; - class Redirect : public IO { public: @@ -81,18 +72,17 @@ class Redirect : public IO Placement placement() const { return _placement; } void set_placement (Placement, void *src); - virtual void run (BufferSet& bufs, jack_nframes_t nframes, jack_nframes_t offset) = 0; + virtual void run (BufferSet& bufs, nframes_t start_frame, nframes_t end_frame, nframes_t nframes, nframes_t offset) = 0; virtual void activate () = 0; virtual void deactivate () = 0; - virtual jack_nframes_t latency() { return 0; } + virtual nframes_t latency() { return 0; } - virtual void set_block_size (jack_nframes_t nframes) {} + virtual void set_block_size (nframes_t nframes) {} sigc::signal active_changed; sigc::signal placement_changed; sigc::signal AutomationPlaybackChanged; sigc::signal AutomationChanged; - sigc::signal GoingAway; static sigc::signal RedirectCreated; @@ -100,9 +90,6 @@ class Redirect : public IO XMLNode& get_state (void); int set_state (const XMLNode&); - StateManager::State* state_factory (string why) const; - Change restore_state (StateManager::State&); - void *get_gui () const { return _gui; } void set_gui (void *p) { _gui = p; } @@ -111,9 +98,6 @@ class Redirect : public IO return 1.0f; } - int load_automation (string path); - int save_automation (string path); - void what_has_automation (set&) const; void what_has_visible_automation (set&) const; const set& what_can_be_automated () const { return can_automate_list; } @@ -121,13 +105,14 @@ class Redirect : public IO void mark_automation_visible (uint32_t, bool); AutomationList& automation_list (uint32_t); - bool find_next_event (jack_nframes_t, jack_nframes_t, ControlEvent&) const; + bool find_next_event (nframes_t, nframes_t, ControlEvent&) const; - virtual void transport_stopped (jack_nframes_t frame) {}; + virtual void transport_stopped (nframes_t frame) {}; + + bool get_next_ab_is_active () const { return _next_ab_is_active; } + void set_next_ab_is_active (bool yn); protected: - void set_placement (const string&, void *src); - /* children may use this stuff as they see fit */ map parameter_automation; @@ -138,15 +123,20 @@ class Redirect : public IO void can_automate (uint32_t); set can_automate_list; - void store_state (RedirectState&) const; - virtual void automation_list_creation_callback (uint32_t, AutomationList&) {} + int set_automation_state (const XMLNode&); + XMLNode& get_automation_state (); + private: bool _active; + bool _next_ab_is_active; Placement _placement; uint32_t _sort_key; void* _gui; /* generic, we don't know or care what this is */ + + int old_set_automation_state (const XMLNode&); + int load_automation (std::string path); }; } // namespace ARDOUR