FP8/16 subscribe to panner changes (add/remove channel)
[ardour.git] / libs / surfaces / faderport8 / fp8_base.h
index efd634f71c80770f1d8bff519112f3af5d62dc46..a77b4a67f0a270bdc6eae3fdbbb9d888134d631c 100644 (file)
 
 #include "pbd/signals.h"
 
-namespace ArdourSurface {
+#ifdef FADERPORT16
+#define FP_NAMESPACE FP16
+#else
+#define FP_NAMESPACE FP8
+#endif
+
+namespace ArdourSurface { namespace FP_NAMESPACE {
 
 /* conveniece wrappers depending on "FP8Base& _base" */
 #define fp8_loop dynamic_cast<BaseUI*>(&_base)->main_loop
@@ -96,7 +102,7 @@ public:
                 std::vector<uint8_t> d;
                 sysexhdr (d);
                 d.push_back (0x12);
-                d.push_back (id & 0x07);
+                d.push_back (id & 0x0f);
                 d.push_back (line & 0x03);
                 d.push_back (align & 0x07);
 
@@ -127,7 +133,11 @@ private:
                d.push_back (0x00);
                d.push_back (0x01);
                d.push_back (0x06);
+#ifdef FADERPORT16
+               d.push_back (0x16);
+#else
                d.push_back (0x02);
+#endif
        }
 };
 
@@ -160,10 +170,11 @@ namespace FP8Types {
                MixMIDI,
                MixOutputs,
                MixFX,
-               MixUser
+               MixUser,
+               MixModeMax = MixUser
        };
 
 };
 
-} /* namespace */
+} /* namespace */
 #endif /* _ardour_surfaces_fp8base_h_ */