PortList debug methods (to be called from gdb)
This commit is contained in:
@@ -229,6 +229,10 @@ protected:
|
||||
}
|
||||
|
||||
virtual BackendPort* port_factory (std::string const& name, ARDOUR::DataType dt, ARDOUR::PortFlags flags) = 0;
|
||||
|
||||
#ifndef NDEBUG
|
||||
void list_ports () const;
|
||||
#endif
|
||||
};
|
||||
|
||||
} /* namespace ARDOUR */
|
||||
|
||||
@@ -121,6 +121,11 @@ public:
|
||||
uint32_t port_name_size () const;
|
||||
std::string my_name () const;
|
||||
|
||||
#ifndef NDEBUG
|
||||
void list_cycle_ports () const;
|
||||
void list_all_ports () const;
|
||||
#endif
|
||||
|
||||
/* Port registration */
|
||||
|
||||
boost::shared_ptr<Port> register_input_port (DataType, const std::string& portname, bool async = false, PortFlags extra_flags = PortFlags (0));
|
||||
|
||||
@@ -724,3 +724,14 @@ PortEngineSharedImpl::update_system_port_latencies ()
|
||||
(*it)->update_connected_latency (false);
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef NDEBUG
|
||||
void
|
||||
PortEngineSharedImpl::list_ports () const
|
||||
{
|
||||
boost::shared_ptr<PortIndex> p = _ports.reader ();
|
||||
for (PortIndex::const_iterator i = p->begin (); i != p->end (); ++i) {
|
||||
std::cout << (*i)->name () << "\n";
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1870,3 +1870,22 @@ PortManager::run_input_meters (pframes_t n_samples, samplecnt_t rate)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef NDEBUG
|
||||
void
|
||||
PortManager::list_all_ports () const
|
||||
{
|
||||
boost::shared_ptr<Ports> plist = _ports.reader();
|
||||
for (Ports::iterator p = plist->begin(); p != plist->end(); ++p) {
|
||||
std::cout << p->first << "\n";
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
PortManager::list_cycle_ports () const
|
||||
{
|
||||
for (Ports::iterator p = _cycle_ports->begin(); p != _cycle_ports->end(); ++p) {
|
||||
std::cout << p->first << "\n";
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user