X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Fautomation_line.h;h=816cefedef9a6260b2e226179178c3fb0b90b878;hb=b402e12d545e9729578e03ad041a131d8a72f37c;hp=02c67d0dcf4abd630dffb58952c9f5453d3a1d1d;hpb=8a128b33d38172ae525ac798c53bc105bc4e2c64;p=ardour.git diff --git a/gtk2_ardour/automation_line.h b/gtk2_ardour/automation_line.h index 02c67d0dcf..816cefedef 100644 --- a/gtk2_ardour/automation_line.h +++ b/gtk2_ardour/automation_line.h @@ -34,6 +34,7 @@ #include "pbd/memento_command.h" #include "ardour/automation_list.h" +#include "ardour/parameter_descriptor.h" #include "ardour/types.h" #include "canvas/types.h" @@ -59,11 +60,12 @@ public: ControlPoints = 0x2, SelectedControlPoints = 0x4 }; - + AutomationLine (const std::string& name, TimeAxisView& tv, ArdourCanvas::Item& parent, boost::shared_ptr al, + const ARDOUR::ParameterDescriptor& desc, Evoral::TimeConverter* converter = 0); virtual ~AutomationLine (); @@ -120,6 +122,7 @@ public: void view_to_model_coord (double& x, double& y) const; void view_to_model_coord_y (double &) const; void model_to_view_coord (double& x, double& y) const; + void model_to_view_coord_y (double &) const; void set_list(boost::shared_ptr list); boost::shared_ptr the_list() const { return alist; } @@ -166,7 +169,7 @@ protected: bool _our_time_converter; VisibleAspects _visible; - + bool _uses_gain_mapping; bool terminal_points_can_slide; bool update_pending; @@ -199,12 +202,10 @@ private: typedef boost::shared_ptr CCP; std::vector contiguous_points; - void sync_model_with_view_point (ControlPoint&); - void sync_model_with_view_points (std::list); + bool sync_model_with_view_point (ControlPoint&); + bool sync_model_with_view_points (std::list); void start_drag_common (double, float); - virtual void change_model (ARDOUR::AutomationList::iterator, double x, double y); - void reset_callback (const Evoral::ControlList&); void list_changed (); @@ -222,6 +223,7 @@ private: */ ARDOUR::framecnt_t _offset; + bool is_stepped() const; void update_visibility (); void reset_line_coords (ControlPoint&); void add_visible_control_point (uint32_t, uint32_t, double, double, ARDOUR::AutomationList::iterator, uint32_t); @@ -234,6 +236,8 @@ private: /** maximum time that a point on this line can be at, relative to the position of its region or start of its track */ ARDOUR::framecnt_t _maximum_time; + const ARDOUR::ParameterDescriptor _desc; + friend class AudioRegionGainLine; };