Ardour  8.12
internal_send.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2009-2011 David Robillard <d@drobilla.net>
3  * Copyright (C) 2009-2012 Carl Hetherington <carl@carlh.net>
4  * Copyright (C) 2009-2017 Paul Davis <paul@linuxaudiosystems.com>
5  * Copyright (C) 2013-2017 Robin Gareus <robin@gareus.org>
6  * Copyright (C) 2018 Len Ovens <len@ovenwerks.net>
7  *
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License along
19  * with this program; if not, write to the Free Software Foundation, Inc.,
20  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21  */
22 
23 #ifndef __ardour_internal_send_h__
24 #define __ardour_internal_send_h__
25 
26 #include "ardour/ardour.h"
27 #include "ardour/send.h"
28 
29 namespace ARDOUR {
30 
32 {
33 public:
34  InternalSend (Session&, std::shared_ptr<Pannable>, std::shared_ptr<MuteMaster>, std::shared_ptr<Route> send_from, std::shared_ptr<Route> send_to, Delivery::Role role = Delivery::Aux, bool ignore_bitslot = false);
35  virtual ~InternalSend ();
36 
37  std::string display_name() const;
38  bool set_name (const std::string&);
39  bool visible() const;
40 
41  int set_state(const XMLNode& node, int version);
42 
44  void run (BufferSet& bufs, samplepos_t start_sample, samplepos_t end_sample, double speed, pframes_t nframes, bool);
45  bool feeds (std::shared_ptr<Route> other) const;
49 
50  std::shared_ptr<Route> source_route() const { return _send_from; }
51  std::shared_ptr<Route> target_route() const { return _send_to; }
52  const PBD::ID& target_id() const { return _send_to_id; }
53 
54  BufferSet const & get_buffers () const {
55  return mixbufs;
56  }
57 
58  bool allow_feedback () const { return _allow_feedback;}
59  void set_allow_feedback (bool yn);
60 
61  void set_can_pan (bool yn);
62  uint32_t pan_outs () const;
63 
64  static PBD::Signal1<void, pframes_t> CycleStart;
65 
66 protected:
67  XMLNode& state() const;
68 
69 private:
71  std::shared_ptr<Route> _send_from;
72  std::shared_ptr<Route> _send_to;
78 
82  int after_connect ();
83  void init_gain ();
84  int use_target (std::shared_ptr<Route>, bool update_name = true);
86  void ensure_mixbufs ();
87 
88  void propagate_solo ();
89 };
90 
91 } // namespace ARDOUR
92 
93 #endif /* __ardour_send_h__ */
std::string display_name() const
PBD::ScopedConnection connect_c
Definition: internal_send.h:75
const PBD::ID & target_id() const
Definition: internal_send.h:52
bool configure_io(ChanCount in, ChanCount out)
PBD::ScopedConnection source_connection
Definition: internal_send.h:76
bool feeds(std::shared_ptr< Route > other) const
InternalSend(Session &, std::shared_ptr< Pannable >, std::shared_ptr< MuteMaster >, std::shared_ptr< Route > send_from, std::shared_ptr< Route > send_to, Delivery::Role role=Delivery::Aux, bool ignore_bitslot=false)
void set_allow_feedback(bool yn)
bool set_name(const std::string &)
void set_can_pan(bool yn)
uint32_t pan_outs() const
int set_block_size(pframes_t)
BufferSet const & get_buffers() const
Definition: internal_send.h:54
int set_state(const XMLNode &node, int version)
XMLNode & state() const
PBD::ScopedConnectionList target_connections
Definition: internal_send.h:77
void send_to_property_changed(const PBD::PropertyChange &)
bool allow_feedback() const
Definition: internal_send.h:58
bool visible() const
void run(BufferSet &bufs, samplepos_t start_sample, samplepos_t end_sample, double speed, pframes_t nframes, bool)
void cycle_start(pframes_t)
std::shared_ptr< Route > source_route() const
Definition: internal_send.h:50
int use_target(std::shared_ptr< Route >, bool update_name=true)
bool can_support_io_configuration(const ChanCount &in, ChanCount &out)
static PBD::Signal1< void, pframes_t > CycleStart
Definition: internal_send.h:64
std::shared_ptr< Route > target_route() const
Definition: internal_send.h:51
std::shared_ptr< Route > _send_from
Definition: internal_send.h:71
std::shared_ptr< Route > _send_to
Definition: internal_send.h:72
Definition: id.h:35
Definition: xml++.h:114
#define LIBARDOUR_API
uint32_t pframes_t
Temporal::samplepos_t samplepos_t