def __init__(self, *a, **k): super(Eq8DeviceDecorator, self).__init__(*a, **k) self.band = EnumWrappingParameter( name=b'Band', parent=self, values_host=self, index_property_host=self.view, values_property=b'available_band_indices', index_property=b'selected_band') self.mode = EnumWrappingParameter( name=b'Eq Mode', parent=self, values_host=self, index_property_host=self, values_property=b'available_global_modes', index_property=b'global_mode') self.edit_switch = BoolWrappingParameter(name=b'Edit Mode', parent=self, property_host=self, source_property=b'edit_mode') self.oversampling = BoolWrappingParameter( name=b'Oversampling', parent=self, property_host=self, source_property=b'oversample') self.left_right_curve_switch_option = DeviceSwitchOption( name=b'Left/Right', labels=[b'Left', b'Right'], parameter=self.edit_switch) self.mid_side_curve_switch_option = DeviceSwitchOption( name=b'Mid/Side', labels=[b'Mid', b'Side'], parameter=self.edit_switch) self._additional_parameters = (self.band, self.mode, self.edit_switch, self.oversampling) self._additional_options = (self.left_right_curve_switch_option, self.mid_side_curve_switch_option) self.register_disconnectables(self._additional_parameters + self._additional_options) self.__on_parameters_changed.subject = self
def __init__(self, *a, **k): super(HybridReverbDeviceDecorator, self).__init__(*a, **k) self.main_section_labels = [u'Convolution', u'Algo', u'Mix', u'EQ'] self.routing_full_labels = [u'Serial', u'Parallel', u'Algorithm', u'Convolution'] self.routing_option_labels = [u'Ser.', u'Par.', u'Alg.', u'Cv.'] self.vintage_labels = [u'Off', u'Subtle', u'Old', u'Older', u'Extreme'] self.band_names_labels = [u'1&4', u'2&3'] self.pre_delay_sync_labels = [u'Ms', u'Sync'] self.filter_types_labels = [u'Cut', u'Shelf'] self.routing_live_parameter = get_parameter_by_name(self, u'Routing') self.vintage_live_parameter = get_parameter_by_name(self, u'Vintage') self.pre_delay_sync_live_parameter = get_parameter_by_name(self, u'P.Dly Sync') self.eq_low_type_live_parameter = get_parameter_by_name(self, u'EQ Low Type') self.eq_high_type_live_parameter = get_parameter_by_name(self, u'EQ High Type') self.eq_on_live_parameter = get_parameter_by_name(self, u'EQ On') self.freeze_live_parameter = get_parameter_by_name(self, u'Freeze') self.freeze_in_live_parameter = get_parameter_by_name(self, u'Freeze In') self.eq_prealgo_live_parameter = get_parameter_by_name(self, u'EQ Pre Algo') self.bass_mono_live_parameter = get_parameter_by_name(self, u'Bass Mono') self._band_names_provider = NotifyingList(available_values=self.band_names_labels, default_value=0) self.band = EnumWrappingParameter(name=u'Band', parent=self, values_host=self._band_names_provider, index_property_host=self._band_names_provider, values_property=u'available_values', index_property=u'index') self._main_section_provider = NotifyingList(available_values=self.main_section_labels, default_value=0) self.main_section = EnumWrappingParameter(name=u'Section', parent=self, values_host=self._main_section_provider, index_property_host=self._main_section_provider, values_property=u'available_values', index_property=u'index') self.routing_switch = DeviceSwitchOption(name=u'Routing Switch', parameter=self.routing_live_parameter, labels=self.routing_option_labels) self.feedback_ms_sync_switch = DeviceSwitchOption(name=u'Ms Sync Switch', parameter=self.pre_delay_sync_live_parameter, labels=self.pre_delay_sync_labels) self.eq_low_type_switch = DeviceSwitchOption(name=u'Low Type Switch', parameter=self.eq_low_type_live_parameter, labels=self.filter_types_labels) self.eq_high_type_switch = DeviceSwitchOption(name=u'High Type Switch', parameter=self.eq_high_type_live_parameter, labels=self.filter_types_labels) self.ir_post_processing_bool = BoolWrappingParameter(name=u'Ir Post Processing Bool', parent=self, property_host=self, source_property=u'ir_time_shaping_on') self.ir_post_processing_option = DeviceOnOffOption(name=u'Shape', property_host=self.ir_post_processing_bool) self.eq_on_option = DeviceOnOffOption(name=u'EQ', property_host=self.eq_on_live_parameter) self.freeze_option = DeviceOnOffOption(name=u'Freeze', property_host=self.freeze_live_parameter) self.freeze_in_option = DeviceOnOffOption(name=u'Freeze In', property_host=self.freeze_in_live_parameter) self.prealgo_option = DeviceOnOffOption(name=u'Pre Algo', property_host=self.eq_prealgo_live_parameter) self.bass_mono_option = DeviceOnOffOption(name=u'Bass Mono', property_host=self.bass_mono_live_parameter) self.ir_attack_time_parameter = WrappingParameter(name=u'Ir Attack Time', parent=self, property_host=self, source_property=u'ir_attack_time', display_value_conversion=to_ms_display, from_property_value=user_to_linear_exp(0.0, 3.0, 3.33), to_property_value=linear_to_user_exp(0.0, 3.0, 3.33)) self.ir_decay_time_parameter = WrappingParameter(name=u'Ir Decay Time', parent=self, property_host=self, source_property=u'ir_decay_time', display_value_conversion=to_ms_display, from_property_value=user_to_linear_exp(0.02, 20.0, 3.33), to_property_value=linear_to_user_exp(0.02, 20.0, 3.33)) self.ir_size_factor_parameter = WrappingParameter(name=u'Ir Size Factor', parent=self, property_host=self, source_property=u'ir_size_factor', display_value_conversion=to_percentage_display, from_property_value=user_to_linear_log(0.2, 5.0), to_property_value=linear_to_user_log(0.2, 5.0)) self.ir_category_list_parameter = EnumWrappingParameter(name=u'IR Category', parent=self, values_host=self._live_object, index_property_host=self, values_property=u'ir_category_list', index_property=u'ir_category_index') self.ir_file_list_parameter = EnumWrappingParameter(name=u'IR', parent=self, values_host=self._live_object, index_property_host=self, values_property=u'ir_file_list', index_property=u'ir_file_index') self.vintage_enum_copy = NotifyingList(available_values=self.vintage_labels, default_value=0) self.vintage_parameter_copy = EnumWrappingParameter(name=u'Vintage Copy', parent=self, values_host=self.vintage_enum_copy, index_property_host=self.vintage_enum_copy, values_property=u'available_values', index_property=u'index') self.routing_parameter_enum = NotifyingList(available_values=self.routing_full_labels, default_value=0) self.routing_parameter_eq_off = EnumWrappingParameter(name=u'Routing Eq Off', parent=self, values_host=self.routing_parameter_enum, index_property_host=self.routing_parameter_enum, values_property=u'available_values', index_property=u'index') self.routing_parameter_eq_on_prealgo_off = EnumWrappingParameter(name=u'Routing Eq On PreAlgo Off', parent=self, values_host=self.routing_parameter_enum, index_property_host=self.routing_parameter_enum, values_property=u'available_values', index_property=u'index') self.routing_parameter_eq_on_prealgo_on = EnumWrappingParameter(name=u'Routing Eq On PreAlgo On', parent=self, values_host=self.routing_parameter_enum, index_property_host=self.routing_parameter_enum, values_property=u'available_values', index_property=u'index') self.on_routing_parameter_change.subject = self.routing_live_parameter self.on_routing_parameter_change() self.on_routing_parameter_eq_off_change.subject = self.routing_parameter_eq_off self.on_routing_parameter_eq_off_change() self.on_routing_parameter_eq_on_prealgo_on_change.subject = self.routing_parameter_eq_on_prealgo_on self.on_routing_parameter_eq_on_prealgo_on_change() self.on_routing_parameter_eq_on_prealgo_off_change.subject = self.routing_parameter_eq_on_prealgo_off self.on_routing_parameter_eq_on_prealgo_off_change() self.on_vintage_parameter_change.subject = self.vintage_live_parameter self.on_vintage_parameter_change() self.on_vintage_copy_parameter_change.subject = self.vintage_parameter_copy self.on_vintage_copy_parameter_change() self.on_shape_option_change.subject = self.ir_post_processing_bool self.on_shape_option_change() self._additional_parameters = (self.band, self.main_section, self.ir_post_processing_bool, self.ir_attack_time_parameter, self.ir_decay_time_parameter, self.ir_size_factor_parameter, self.ir_category_list_parameter, self.ir_file_list_parameter, self.vintage_parameter_copy, self.routing_parameter_eq_off, self.routing_parameter_eq_on_prealgo_on, self.routing_parameter_eq_on_prealgo_off) self.register_disconnectable(self._additional_parameters)