boost::shared_ptr<AutomationControl> pan_frontback_control;
boost::shared_ptr<AutomationControl> pan_lfe_control;
- boost::shared_ptr<Panner> panner() const { return _panner; }
+ boost::shared_ptr<Panner> panner() const { return _panner.lock(); }
void set_panner(boost::shared_ptr<Panner>);
Session& session() { return _session; }
bool has_state() const { return _has_state; }
protected:
- boost::shared_ptr<Panner> _panner;
+ boost::weak_ptr<Panner> _panner;
AutoState _auto_state;
AutoStyle _auto_style;
gint _touching;
string
Pannable::value_as_string (boost::shared_ptr<AutomationControl> ac) const
{
- if (_panner) {
- return _panner->value_as_string (ac);
+ boost::shared_ptr<Panner> p = panner ();
+
+ if (p) {
+ return p->value_as_string (ac);
}
return Automatable::value_as_string (ac);
#include "ardour/audio_buffer.h"
#include "ardour/buffer_set.h"
+#include "ardour/debug.h"
#include "ardour/panner.h"
#include "ardour/pannable.h"
#include "ardour/session.h"
Panner::~Panner ()
{
+ DEBUG_TRACE(PBD::DEBUG::Destruction, string_compose ("panner @ %1 destructor, pannable is %2\n", this, _pannable));
}
void
#include <glibmm.h>
#include "pbd/cartesian.h"
+#include "pbd/boost_debug.h"
#include "pbd/convert.h"
#include "pbd/error.h"
#include "pbd/failed_constructor.h"
#include "ardour/audio_buffer.h"
#include "ardour/automatable.h"
#include "ardour/buffer_set.h"
+#include "ardour/debug.h"
#include "ardour/pannable.h"
#include "ardour/panner.h"
#include "ardour/panner_manager.h"
PannerShell::~PannerShell ()
{
+ DEBUG_TRACE(DEBUG::Destruction, string_compose ("panner shell for %1 destructor, pannable is %2\n", _name, _pannable));
}
void
abort ();
}
- _panner.reset (pi->descriptor.factory (_pannable, _session.get_speakers()));
+ Panner* p = pi->descriptor.factory (_pannable, _session.get_speakers());
+ boost_debug_shared_ptr_mark_interesting (p, "Panner");
+ _panner.reset (p);
_panner->configure_io (in, out);
Changed (); /* EMIT SIGNAL */
#include "pbd/memento_command.h"
#include "pbd/stacktrace.h"
#include "pbd/convert.h"
+#include "pbd/boost_debug.h"
#include "evoral/Curve.hpp"
/* panning */
- _pannable.reset (new Pannable (_session));
+ Pannable* p = new Pannable (_session);
+ boost_debug_shared_ptr_mark_interesting (p, "Pannable");
+ _pannable.reset (p);
/* input and output objects */
/* not strictly necessary, but doing it here allows the shared_ptr debugging to work */
playlists.reset ();
- boost_debug_list_ptrs ();
-
delete _locations;
delete _speakers;
DEBUG_TRACE (DEBUG::Destruction, "Session::destroy() done\n");
+
+ boost_debug_list_ptrs ();
}
void