From 86f24d20e1616ffaafc97de65db49fd6a91270f8 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Tue, 16 Jun 2009 14:58:33 +0000 Subject: first pass (ok, third really) at internal send+return - audio routing inside ardour without JACK. lots still to do, but at least the obvious works git-svn-id: svn://localhost/ardour2/branches/3.0@5202 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/ardour/internal_return.h | 60 ++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 libs/ardour/ardour/internal_return.h (limited to 'libs/ardour/ardour/internal_return.h') diff --git a/libs/ardour/ardour/internal_return.h b/libs/ardour/ardour/internal_return.h new file mode 100644 index 0000000000..6aa8bfe7b4 --- /dev/null +++ b/libs/ardour/ardour/internal_return.h @@ -0,0 +1,60 @@ +/* + Copyright (C) 2009 Paul Davis + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + +*/ + +#ifndef __ardour_internal_return_h__ +#define __ardour_internal_return_h__ + +#include + +#include "ardour/ardour.h" +#include "ardour/return.h" +#include "ardour/buffer_set.h" + +namespace ARDOUR { + +class InternalReturn : public Return +{ + public: + InternalReturn (Session&); + InternalReturn (Session&, const XMLNode&); + + XMLNode& state(bool full); + XMLNode& get_state(void); + int set_state(const XMLNode& node); + + void run (BufferSet& bufs, sframes_t start_frame, sframes_t end_frame, nframes_t nframes); + bool configure_io (ChanCount in, ChanCount out); + bool can_support_io_configuration (const ChanCount& in, ChanCount& out) const; + void set_block_size (nframes_t); + + BufferSet* get_buffers(); + void release_buffers(); + + static sigc::signal CycleStart; + + private: + BufferSet buffers; + uint32_t user_count; + void allocate_buffers (nframes_t); + void cycle_start (nframes_t); +}; + +} // namespace ARDOUR + +#endif /* __ardour_internal_return_h__ */ -- cgit v1.2.3