/// <summary> /// Возвращает новый объект голоса, связанный с этим объектом. /// </summary> /// <returns></returns> private Voice CreateVoice() { var voiceOscA = OscAManager.CreateNewOscillator(); var voiceOscB = OscBManager.CreateNewOscillator(); var voiceFilter = FilterManager.CreateNewFilter(); var oscAEnvelope = OscAVolumeEnvelopeManager.CreateNewEnvelope(); var oscBEnvelope = OscBVolumeEnvelopeManager.CreateNewEnvelope(); var filterEnvelope = FilterCutoffEnvelopeManager.CreateNewEnvelope(); filterEnvelope.SetAmplitude(0); var voice = new Voice(Plugin, voiceOscA, voiceOscB, voiceFilter, oscAEnvelope, oscBEnvelope, filterEnvelope); voice.Modulation = modulationType; return(voice); }