39 PBD::Signal1<void,AutomationList *> AutomationList::AutomationListCreated;
44 cerr << prefix << &al << endl;
45 for (AutomationList::const_iterator i = al.
begin(); i != al.
end(); ++i) {
46 cerr << prefix <<
'\t' << (*i)->when <<
',' << (*i)->value << endl;
159 if (
this != &other) {
162 ControlList::operator= (other);
177 ControlList::maybe_signal_changed ();
179 if (!ControlList::frozen()) {
215 if (g_atomic_int_get (&
_touching) == 0) {
265 snprintf (buf,
sizeof (buf),
"%.12g",
_min_yval);
267 snprintf (buf,
sizeof (buf),
"%.12g",
_max_yval);
304 str << (double) (*xx)->when;
306 str <<(
double) (*xx)->value;
329 if (content_node->
content().empty()) {
333 ControlList::freeze ();
336 stringstream str (content_node->
content());
357 error <<
_(
"automation list: cannot load coordinates from XML, all points ignored") <<
endmsg;
377 if (node.
name() ==
X_(
"events")) {
382 if (node.
name() ==
X_(
"Envelope") || node.
name() ==
X_(
"FadeOut") || node.
name() ==
X_(
"FadeIn")) {
384 if ((nsos = node.
child (
X_(
"AutomationList")))) {
397 ControlList::freeze ();
400 for (i = elist.begin(); i != elist.end(); ++i) {
402 if ((prop = (*i)->property (
"x")) == 0) {
403 error <<
_(
"automation list: no x-coordinate stored for control point (point ignored)") <<
endmsg;
408 if ((prop = (*i)->property (
"y")) == 0) {
409 error <<
_(
"automation list: no y-coordinate stored for control point (point ignored)") <<
endmsg;
422 if (node.
name() !=
X_(
"AutomationList") ) {
432 if ((prop = node.
property (
X_(
"automation-id"))) != 0){
435 warning <<
"Legacy session: automation list has no automation-id property." <<
endmsg;
438 if ((prop = node.
property (
X_(
"interpolation-style"))) != 0) {
444 if ((prop = node.
property (
X_(
"default"))) != 0){
450 if ((prop = node.
property (
X_(
"style"))) != 0) {
456 if ((prop = node.
property (
X_(
"state"))) != 0) {
466 if ((prop = node.
property (
X_(
"min-yval"))) != 0) {
472 if ((prop = node.
property (
X_(
"max-yval"))) != 0) {
478 bool have_events =
false;
480 for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
481 if ((*niter)->name() ==
X_(
"events")) {
503 static_cast<ControlList const &> (*
this) != static_cast<ControlList const &> (other) ||
void set_automation_state(AutoState)
XMLNodeList::iterator XMLNodeIterator
int atoi(const string &s)
virtual boost::shared_ptr< ControlList > create(const Evoral::Parameter &id, const Evoral::ParameterDescriptor &desc)
const std::string & content() const
const std::string & value() const
int deserialize_events(const XMLNode &)
AutomationListProperty(PBD::PropertyDescriptor< boost::shared_ptr< AutomationList > > d, Ptr p)
XMLNode & state(bool full)
const std::string & name() const
int set_state(const XMLNode &, int version)
AutomationList & operator=(const AutomationList &)
LIBPBD_API Transmitter error
LIBPBD_API Transmitter warning
AutoStyle string_to_auto_style(std::string)
const XMLNodeList & children(const std::string &str=std::string()) const
void start_write_pass(double time)
std::ostream & endmsg(std::ostream &ostr)
LIBARDOUR_API PBD::PropertyDescriptor< framepos_t > start
void maybe_signal_changed()
std::list< XMLNode * > XMLNodeList
PropertyID property_id() const
XMLProperty * property(const char *)
std::string auto_state_to_string(AutoState)
#define string_2_enum(str, e)
void stop_touch(bool mark, double when)
PBD::PropertyBase * clone() const
AutomationList(const Evoral::Parameter &id, const Evoral::ParameterDescriptor &desc)
const PBD::ID & id() const
void set_automation_style(AutoStyle m)
bool set_id(const XMLNode &)
void create_curve_if_necessary()
void fast_simple_add(double when, double value)
static EventTypeMap & instance()
Evoral::Parameter from_symbol(const std::string &str) const
static int loading_state_version
PBD::Signal0< void > automation_style_changed
bool _changed_when_thawed
void start_touch(double when)
bool operator!=(const AutomationList &) const
XMLProperty * add_property(const char *name, const std::string &value)
PBD::Signal0< void > StateChanged
void add_child_nocopy(XMLNode &)
LIBEVORAL_API uint64_t ControlList
const std::string & set_content(const std::string &)
XMLNode & serialize_events()
XMLNode * child(const char *) const
std::string auto_style_to_string(AutoStyle)
AutoState string_to_auto_state(std::string)
static PBD::Signal1< void, AutomationList * > AutomationListCreated
XMLNodeList::const_iterator XMLNodeConstIterator
EventList::iterator iterator
std::string string_compose(const std::string &fmt, const T1 &o1)
double atof(const string &s)
PBD::Signal1< void, AutoState > automation_state_changed
InterpolationStyle _interpolation