Vapor: Add surround types/enum
This commit is contained in:
parent
c7772c220e
commit
9bb4d0dcf8
@ -42,10 +42,11 @@ class LIBARDOUR_API MuteMaster : public SessionHandleRef, public PBD::Stateful
|
||||
public:
|
||||
/** deliveries to mute when the channel is "muted" */
|
||||
enum MutePoint {
|
||||
PreFader = 0x1, ///< mute all pre-fader sends
|
||||
PostFader = 0x2, ///< mute all post-fader sends
|
||||
Listen = 0x4, ///< mute listen out
|
||||
Main = 0x8 ///< mute main out
|
||||
PreFader = 0x1, ///< mute all pre-fader sends
|
||||
PostFader = 0x2, ///< mute all post-fader sends
|
||||
Listen = 0x4, ///< mute listen out
|
||||
Main = 0x8, ///< mute main out
|
||||
SurroundSend = 0x10 ///< mute surround send (if any)
|
||||
};
|
||||
|
||||
static const MutePoint AllPoints;
|
||||
|
@ -113,25 +113,26 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful
|
||||
MasterOut = 0x20,
|
||||
MonitorOut = 0x40,
|
||||
Auditioner = 0x80,
|
||||
#ifdef MIXBUS
|
||||
Mixbus = 0x1000,
|
||||
#endif
|
||||
/* These are for sharing Stripable states between the GUI and other
|
||||
* user interfaces/control surfaces
|
||||
*/
|
||||
Hidden = 0x100,
|
||||
#ifdef MIXBUS
|
||||
MixbusEditorHidden = 0x800,
|
||||
#endif
|
||||
/* single bit indicates that the group order is set */
|
||||
OrderSet = 0x400,
|
||||
|
||||
#ifdef MIXBUS
|
||||
MixbusEditorHidden = 0x800,
|
||||
Mixbus = 0x1000,
|
||||
#endif
|
||||
/* bus type for monitor mixes */
|
||||
FoldbackBus = 0x2000,
|
||||
|
||||
/* has TriggerBox, show on TriggerUI page */
|
||||
TriggerTrack = 0x4000,
|
||||
|
||||
/* bus is the surround master */
|
||||
SurroundMaster = 0x8000,
|
||||
|
||||
/* special mask to delect out "state" bits */
|
||||
#ifdef MIXBUS
|
||||
StatusMask = (Hidden | MixbusEditorHidden | TriggerTrack),
|
||||
@ -139,8 +140,14 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful
|
||||
StatusMask = (Hidden | TriggerTrack),
|
||||
#endif
|
||||
|
||||
/* dedicated [output] busses */
|
||||
MainBus = (MasterOut|MonitorOut|FoldbackBus|SurroundMaster),
|
||||
|
||||
/* These can exist only once and require special attention to be removed */
|
||||
Singleton = (MasterOut|MonitorOut|SurroundMaster),
|
||||
|
||||
/* special mask to delect select type bits */
|
||||
TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner|FoldbackBus)
|
||||
TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner|FoldbackBus|SurroundMaster)
|
||||
};
|
||||
|
||||
static const Flag AllStripables; /* mask to use for any route or VCA (but not auditioner) */
|
||||
@ -178,7 +185,7 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful
|
||||
|
||||
bool hidden() const { return _flags & Hidden; }
|
||||
bool trigger_track () const { return _flags & TriggerTrack; }
|
||||
bool special(bool with_master = true) const { return _flags & ((with_master ? MasterOut : 0)|MonitorOut|Auditioner); }
|
||||
bool special(bool with_master = true) const { return _flags & ((with_master ? MasterOut : 0)|SurroundMaster|MonitorOut|Auditioner); }
|
||||
|
||||
bool flag_match (Flag f) const {
|
||||
/* no flags, match all */
|
||||
|
@ -128,11 +128,13 @@ CONFIG_VARIABLE (bool, mute_affects_pre_fader, "mute-affects-pre-fader", false)
|
||||
CONFIG_VARIABLE (bool, mute_affects_post_fader, "mute-affects-post-fader", true)
|
||||
CONFIG_VARIABLE (bool, mute_affects_control_outs, "mute-affects-control-outs", true)
|
||||
CONFIG_VARIABLE (bool, mute_affects_main_outs, "mute-affects-main-outs", true)
|
||||
CONFIG_VARIABLE (bool, mute_affects_surround_sends, "mute-affects-surround-sends", true)
|
||||
CONFIG_VARIABLE (MonitorModel, monitoring_model, "monitoring-model", ExternalMonitoring)
|
||||
CONFIG_VARIABLE (ListenPosition, listen_position, "listen-position", AfterFaderListen)
|
||||
CONFIG_VARIABLE (PFLPosition, pfl_position, "pfl-position", PFLFromAfterProcessors)
|
||||
CONFIG_VARIABLE (AFLPosition, afl_position, "afl-position", AFLFromAfterProcessors)
|
||||
CONFIG_VARIABLE (bool, use_monitor_bus, "use-monitor-bus", false)
|
||||
CONFIG_VARIABLE (bool, use_surround_master, "use-surround-master", false)
|
||||
|
||||
CONFIG_VARIABLE (bool, solo_control_is_listen_control, "solo-control-is-listen-control", false)
|
||||
CONFIG_VARIABLE (bool, exclusive_solo, "exclusive-solo", false)
|
||||
|
@ -76,6 +76,9 @@ class LIBARDOUR_API Stripable : public SessionObject,
|
||||
bool is_master() const { return _presentation_info.flags() & PresentationInfo::MasterOut; }
|
||||
bool is_monitor() const { return _presentation_info.flags() & PresentationInfo::MonitorOut; }
|
||||
bool is_foldbackbus() const { return _presentation_info.flags() & PresentationInfo::FoldbackBus; }
|
||||
bool is_surround_master() const { return _presentation_info.flags() & PresentationInfo::SurroundMaster; }
|
||||
bool is_main_bus() const { return _presentation_info.flags() & PresentationInfo::MainBus; }
|
||||
bool is_singleton () const { return _presentation_info.flags() & PresentationInfo::Singleton; }
|
||||
|
||||
int set_state (XMLNode const&, int);
|
||||
|
||||
|
@ -176,6 +176,12 @@ enum AutomationType {
|
||||
InsertReturnLevel,
|
||||
MainOutVolume,
|
||||
MidiVelocityAutomation,
|
||||
PanSurroundX,
|
||||
PanSurroundY,
|
||||
PanSurroundZ,
|
||||
PanSurroundSize,
|
||||
PanSurroundSnap,
|
||||
BinauralRenderMode,
|
||||
|
||||
/* used only by Controllable Descriptor to access send parameters */
|
||||
|
||||
@ -959,7 +965,6 @@ struct ProcessedRanges {
|
||||
ProcessedRanges() : start { 0, 0 }, end { 0, 0 }, cnt (0) {}
|
||||
};
|
||||
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
||||
/* for now, break the rules and use "using" to make this "global" */
|
||||
|
@ -101,6 +101,18 @@ public:
|
||||
uint32_t auto_end;
|
||||
uint32_t auto_parameter;
|
||||
uint32_t auto_value;
|
||||
uint32_t surr_MetaData;
|
||||
uint32_t surr_Channel;
|
||||
uint32_t surr_PosX;
|
||||
uint32_t surr_PosY;
|
||||
uint32_t surr_PosZ;
|
||||
uint32_t surr_Size;
|
||||
uint32_t surr_Snap;
|
||||
uint32_t surr_Settings;
|
||||
uint32_t surr_BinauralRenderMode;
|
||||
uint32_t surr_ChannelCount;
|
||||
uint32_t surr_DownmixMode;
|
||||
uint32_t surr_WarpMode;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
@ -209,6 +209,18 @@ Automatable::describe_parameter (Evoral::Parameter param)
|
||||
return _("Width");
|
||||
} else if (param.type() == PanElevationAutomation) {
|
||||
return _("Elevation");
|
||||
} else if (param.type() == PanSurroundX) {
|
||||
return _("Left/Right");
|
||||
} else if (param.type() == PanSurroundY) {
|
||||
return _("Front/Back");
|
||||
} else if (param.type() == PanSurroundZ) {
|
||||
return _("Elevation");
|
||||
} else if (param.type() == PanSurroundSize) {
|
||||
return _("Object Size");
|
||||
} else if (param.type() == PanSurroundSnap) {
|
||||
return _("Snap to Speaker");
|
||||
} else if (param.type() == BinauralRenderMode) {
|
||||
return _("Binaural Render mode");
|
||||
} else if (param.type() == PhaseAutomation) {
|
||||
return _("Polarity Invert");
|
||||
} else if (param.type() == MidiVelocityAutomation) {
|
||||
|
@ -210,6 +210,12 @@ setup_enum_writer ()
|
||||
REGISTER_ENUM (InsertReturnLevel);
|
||||
REGISTER_ENUM (MainOutVolume);
|
||||
REGISTER_ENUM (MidiVelocityAutomation);
|
||||
REGISTER_ENUM (PanSurroundX);
|
||||
REGISTER_ENUM (PanSurroundY);
|
||||
REGISTER_ENUM (PanSurroundZ);
|
||||
REGISTER_ENUM (PanSurroundSize);
|
||||
REGISTER_ENUM (PanSurroundSnap);
|
||||
REGISTER_ENUM (BinauralRenderMode);
|
||||
REGISTER (_AutomationType);
|
||||
|
||||
REGISTER_ENUM (Off);
|
||||
@ -727,6 +733,7 @@ setup_enum_writer ()
|
||||
REGISTER_CLASS_ENUM (MuteMaster, PostFader);
|
||||
REGISTER_CLASS_ENUM (MuteMaster, Listen);
|
||||
REGISTER_CLASS_ENUM (MuteMaster, Main);
|
||||
REGISTER_CLASS_ENUM (MuteMaster, SurroundSend);
|
||||
REGISTER_BITS (_MuteMaster_MutePoint);
|
||||
|
||||
REGISTER_CLASS_ENUM (IO, Input);
|
||||
@ -807,6 +814,7 @@ setup_enum_writer ()
|
||||
REGISTER_CLASS_ENUM (PresentationInfo, OrderSet);
|
||||
REGISTER_CLASS_ENUM (PresentationInfo, FoldbackBus);
|
||||
REGISTER_CLASS_ENUM (PresentationInfo, TriggerTrack);
|
||||
REGISTER_CLASS_ENUM (PresentationInfo, SurroundMaster);
|
||||
#ifdef MIXBUS
|
||||
REGISTER_CLASS_ENUM (PresentationInfo, MixbusEditorHidden);
|
||||
#endif
|
||||
|
@ -172,6 +172,24 @@ EventTypeMap::from_symbol(const string& str) const
|
||||
p_type = MonitoringAutomation;
|
||||
} else if (str == "pan-lfe") {
|
||||
p_type = PanLFEAutomation;
|
||||
} else if (str.length() > 10 && str.substr(0, 10) == "pan-sur-x-") {
|
||||
p_type = PanSurroundX;
|
||||
p_id = atoi(str.c_str()+10);
|
||||
} else if (str.length() > 10 && str.substr(0, 10) == "pan-sur-y-") {
|
||||
p_id = atoi(str.c_str()+10);
|
||||
p_type = PanSurroundY;
|
||||
} else if (str.length() > 10 && str.substr(0, 10) == "pan-sur-z-") {
|
||||
p_id = atoi(str.c_str()+10);
|
||||
p_type = PanSurroundZ;
|
||||
} else if (str.length() > 13 && str.substr(0, 13) == "pan-sur-size-") {
|
||||
p_id = atoi(str.c_str()+13);
|
||||
p_type = PanSurroundSize;
|
||||
} else if (str.length() > 13 && str.substr(0, 13) == "pan-sur-snap-") {
|
||||
p_id = atoi(str.c_str()+13);
|
||||
p_type = PanSurroundSnap;
|
||||
} else if (str.length() > 21 && str.substr(0, 21) == "binaural-render-mode-") {
|
||||
p_type = BinauralRenderMode;
|
||||
p_id = atoi(str.c_str()+21);
|
||||
} else if (str.length() > 10 && str.substr(0, 10) == "parameter-") {
|
||||
p_type = PluginAutomation;
|
||||
p_id = atoi(str.c_str()+10);
|
||||
@ -254,6 +272,18 @@ EventTypeMap::to_symbol(const Evoral::Parameter& param) const
|
||||
return "pan-frontback";
|
||||
} else if (t == PanLFEAutomation) {
|
||||
return "pan-lfe";
|
||||
} else if (t == PanSurroundX) {
|
||||
return std::string("pan-sur-x-") + PBD::to_string(param.id());
|
||||
} else if (t == PanSurroundY) {
|
||||
return std::string("pan-sur-y-") + PBD::to_string(param.id());
|
||||
} else if (t == PanSurroundZ) {
|
||||
return std::string("pan-sur-z-") + PBD::to_string(param.id());
|
||||
} else if (t == PanSurroundSize) {
|
||||
return std::string("pan-sur-size-") + PBD::to_string(param.id());
|
||||
} else if (t == PanSurroundSnap) {
|
||||
return std::string("pan-sur-snap-") + PBD::to_string(param.id());
|
||||
} else if (t == BinauralRenderMode) {
|
||||
return std::string("binaural-render-mode-") + PBD::to_string(param.id());
|
||||
} else if (t == SoloAutomation) {
|
||||
return "solo";
|
||||
} else if (t == MuteAutomation) {
|
||||
|
@ -1378,6 +1378,7 @@ LuaBindings::common (lua_State* L)
|
||||
.addFunction ("is_private_route", &Stripable::is_private_route)
|
||||
.addFunction ("is_master", &Stripable::is_master)
|
||||
.addFunction ("is_monitor", &Stripable::is_monitor)
|
||||
.addFunction ("is_surround_master", &Stripable::is_surround_master)
|
||||
.addFunction ("is_hidden", &Stripable::is_hidden)
|
||||
.addFunction ("is_selected", &Stripable::is_selected)
|
||||
.addFunction ("gain_control", &Stripable::gain_control)
|
||||
|
@ -39,7 +39,7 @@ using namespace std;
|
||||
const string MuteMaster::xml_node_name (X_("MuteMaster"));
|
||||
|
||||
const MuteMaster::MutePoint MuteMaster::AllPoints = MuteMaster::MutePoint(
|
||||
PreFader|PostFader|Listen|Main);
|
||||
PreFader|PostFader|Listen|Main|SurroundSend);
|
||||
|
||||
MuteMaster::MuteMaster (Session& s, Muteable& m, const std::string&)
|
||||
: SessionHandleRef (s)
|
||||
@ -66,6 +66,10 @@ MuteMaster::MuteMaster (Session& s, Muteable& m, const std::string&)
|
||||
if (Config->get_mute_affects_main_outs ()) {
|
||||
_mute_point = MutePoint (_mute_point | Main);
|
||||
}
|
||||
|
||||
if (Config->get_mute_affects_surround_sends ()) {
|
||||
_mute_point = MutePoint (_mute_point | SurroundSend);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -102,6 +102,31 @@ ParameterDescriptor::ParameterDescriptor(const Evoral::Parameter& parameter)
|
||||
upper = 2.0f;
|
||||
normal = 1.0f;
|
||||
break;
|
||||
case PanSurroundX:
|
||||
upper = 1.0f;
|
||||
normal = 0.5f;
|
||||
break;
|
||||
case PanSurroundY:
|
||||
upper = 1.0f;
|
||||
normal = 0.0f;
|
||||
break;
|
||||
case PanSurroundZ:
|
||||
case PanSurroundSize:
|
||||
upper = 1.0f;
|
||||
normal = 0.0f;
|
||||
break;
|
||||
case BinauralRenderMode:
|
||||
enumeration = true;
|
||||
integer_step = true;
|
||||
upper = 3.0f;
|
||||
normal = 0.0f;
|
||||
scale_points = std::shared_ptr<ScalePoints>(new ScalePoints());
|
||||
scale_points->insert (std::make_pair (_("Mid"), 0));
|
||||
scale_points->insert (std::make_pair (_("Off"), 1));
|
||||
scale_points->insert (std::make_pair (_("Near"), 2));
|
||||
scale_points->insert (std::make_pair (_("Far"), 3));
|
||||
break;
|
||||
case PanSurroundSnap:
|
||||
case SoloAutomation:
|
||||
case MuteAutomation:
|
||||
upper = 1.0f;
|
||||
|
@ -116,8 +116,8 @@ const PresentationInfo::order_t PresentationInfo::max_order = UINT32_MAX;
|
||||
const PresentationInfo::Flag PresentationInfo::Bus = PresentationInfo::Flag (PresentationInfo::AudioBus|PresentationInfo::MidiBus);
|
||||
const PresentationInfo::Flag PresentationInfo::Track = PresentationInfo::Flag (PresentationInfo::AudioTrack|PresentationInfo::MidiTrack);
|
||||
const PresentationInfo::Flag PresentationInfo::Route = PresentationInfo::Flag (PresentationInfo::Bus|PresentationInfo::Track);
|
||||
const PresentationInfo::Flag PresentationInfo::AllRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut|PresentationInfo::FoldbackBus);
|
||||
const PresentationInfo::Flag PresentationInfo::MixerRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut);
|
||||
const PresentationInfo::Flag PresentationInfo::AllRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut|PresentationInfo::FoldbackBus|PresentationInfo::SurroundMaster);
|
||||
const PresentationInfo::Flag PresentationInfo::MixerRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut|PresentationInfo::SurroundMaster);
|
||||
const PresentationInfo::Flag PresentationInfo::AllStripables = PresentationInfo::Flag (PresentationInfo::AllRoutes|PresentationInfo::VCA);
|
||||
const PresentationInfo::Flag PresentationInfo::MixerStripables = PresentationInfo::Flag (PresentationInfo::MixerRoutes|PresentationInfo::VCA);
|
||||
const PresentationInfo::Flag PresentationInfo::MidiIndicatingFlags = PresentationInfo::Flag (PresentationInfo::MidiTrack|PresentationInfo::MidiBus);
|
||||
|
@ -76,6 +76,20 @@ URIMap::URIDs::init(URIMap& uri_map)
|
||||
auto_end = uri_map.uri_to_id(LV2_AUTOMATE_URI__end);
|
||||
auto_parameter = uri_map.uri_to_id(LV2_AUTOMATE_URI__parameter);
|
||||
auto_value = uri_map.uri_to_id(LV2_AUTOMATE_URI__value);
|
||||
|
||||
surr_MetaData = uri_map.uri_to_id("urn:ardour:a-vapor#MetaData");
|
||||
surr_Channel = uri_map.uri_to_id("urn:ardour:a-vapor#Channel");
|
||||
surr_PosX = uri_map.uri_to_id("urn:ardour:a-vapor#PosX");
|
||||
surr_PosY = uri_map.uri_to_id("urn:ardour:a-vapor#PosY");
|
||||
surr_PosZ = uri_map.uri_to_id("urn:ardour:a-vapor#PosZ");
|
||||
surr_Size = uri_map.uri_to_id("urn:ardour:a-vapor#Size");
|
||||
surr_Snap = uri_map.uri_to_id("urn:ardour:a-vapor#Snap");
|
||||
|
||||
surr_Settings = uri_map.uri_to_id("urn:ardour:a-vapor#Settings");
|
||||
surr_BinauralRenderMode = uri_map.uri_to_id("urn:ardour:a-vapor#BinauralRenderMode");
|
||||
surr_ChannelCount = uri_map.uri_to_id("urn:ardour:a-vapor#ChannelCount");
|
||||
surr_DownmixMode = uri_map.uri_to_id("urn:ardour:a-vapor#DownmixMode");
|
||||
surr_WarpMode = uri_map.uri_to_id("urn:ardour:a-vapor#WarpMode");
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user