+ boost::shared_ptr<ARDOUR::Crossfade> xfade;
+
+ Gtk::VBox vpacker;
+
+ struct Point {
+ ~Point();
+
+ ArdourCanvas::Rectangle* box;
+ ArdourCanvas::PolyLine* curve;
+ double x;
+ double y;
+
+ static const int32_t size;
+
+ void move_to (double x, double y, double xfract, double yfract);
+ };
+
+ struct PointSorter {
+ bool operator() (const CrossfadeEditor::Point* a, const CrossfadeEditor::Point *b) {
+ return a->x < b->x;
+ }
+ };
+
+ ArdourCanvas::Rectangle* toplevel;
+ ArdourCanvas::GtkCanvas* canvas;
+
+ struct Half {
+ ArdourCanvas::PolyLine* line;
+ ArdourCanvas::Polygon* shading;
+ std::list<Point*> points;
+ ARDOUR::AutomationList normative_curve; /* 0 - 1.0, linear */
+ ARDOUR::AutomationList gain_curve; /* 0 - 2.0, gain mapping */
+ std::vector<ArdourCanvas::WaveView*> waves;
+
+ Half();
+ };
+
+ enum WhichFade {
+ In = 0,
+ Out = 1
+ };
+
+ Half fade[2];
+ WhichFade current;
+
+ bool point_grabbed;
+ std::vector<Gtk::Button*> fade_out_buttons;
+ std::vector<Gtk::Button*> fade_in_buttons;