示例#1
0
        public polySynthAlgorithmic(ADSRStages adsrInit, int maxVoices)
        {
            this.BufferedA   = new double[320];
            this.BufferedB   = new double[320];
            this.BufferedC   = new double[320];
            this.BufferedD   = new double[320];
            this.bufferCount = 0;

            this.adsr    = adsrInit;
            activeVoices = new LinkedList <int>();

            voices = new voice[maxVoices];

            for (int note = 0; note < maxVoices; note++)
            {
                voices[note] = new voice(adsrInit, SynthHelper.noteToFrequency(note));
                voices[note].reset();
            }
        }
示例#2
0
		public polySynthAlgorithmic(ADSRStages adsrInit, int maxVoices)
		{
			this.BufferedA = new double[320];
			this.BufferedB = new double[320];
			this.BufferedC = new double[320];
			this.BufferedD = new double[320];
			this.bufferCount = 0;

			this.adsr = adsrInit;
			activeVoices = new LinkedList<int>();

			voices = new voice[maxVoices];

			for (int note = 0; note < maxVoices; note++) {
				voices[note] = new voice(adsrInit, SynthHelper.noteToFrequency(note));
				voices[note].reset();

			}
		}