public SoundFxPropertiesControl() { InitializeComponent(); try { _chorus = new ChorusSoundFx();; _compressor = new CompressorSoundFx(); _distortion = new DistortionSoundFx(); _echo = new EchoSoundFx(); _flanger = new FlangerSoundFx(); _gargle = new GargleSoundFx(); _paramEq = new ParamEqSoundFx(); _reverb = new ReverbSoundFx(); FxPropertiesControl.EffectChanged += new Delegates.SoundFxEventHandler(FxPropertiesControlEffectChanged); FrequencyParameterValueControl.UpdateParameter(100, 100000, "Frequency", 50000, 1); FrequencyParameterValueControl.ValueChangedEvent += new Delegates.ParameterValueActionEventHandler(OnFrequencyValueChangedEvent); } catch (System.Exception e) { MessageBox.Show(e.Message); } }
private void SetEchoFxToUi() { if (_soundFx.Type != SoundFxType.Echo) { throw new Exception("Cannot set Echo effect details, effect is of different type"); } EchoSoundFx effect = (EchoSoundFx)_soundFx; SetParamDetails(1, effect.WetDryMix); SetParamDetails(2, effect.Feedback); SetParamDetails(3, effect.LeftDelay); SetParamDetails(4, effect.RightDelay); SetParamDetails(5, effect.PanDelay); SetParamDetails(6, null); WaveformPropertiesControl.Enabled = false; PhasePropertiesControl.Enabled = false; }