예제 #1
0
        public void UpdateClips()
        {
            clips = new List <PureDataClip>();

            foreach (PureDataInfo info in pureData.infoManager.GetAllClipInfos())
            {
                PureDataClip clip = new PureDataClip(info, pureData);
                clips.Add(clip);
            }
        }
예제 #2
0
        public PureDataClip GetClip(string soundName)
        {
            PureDataClip clip = null;

            try {
                clip = nameClipDict[soundName];
            }
            catch {
                Logger.LogError(string.Format("Clip named {0} was not found.", soundName));
            }

            return(clip);
        }
        public void SetClip(PureDataClip clip)
        {
            Clip = clip;
            Load();
            SwitchOff();
            SetSourceSwitch(true);

            Info  = new PureDataInfo(pureData.infoManager.GetInfo(clip.Name), pureData);
            State = PureDataStates.Waiting;
            SetPaused(false);
            SetOutput(Info.output);
            SetVolume(Info.volume + Info.volume * HelperFunctions.RandomRange(-Info.randomVolume, Info.randomVolume));
            SetPitch(Info.pitch + Info.pitch * HelperFunctions.RandomRange(-Info.randomPitch, Info.randomPitch));
            SetPlayRange(Info.playRangeStart, Info.playRangeEnd);
            SetFadeIn(Info.fadeIn);
            SetFadeOut(Info.fadeOut);
            SetLoop(Info.loop);
        }
예제 #4
0
		public void SetClip(PureDataClip clip) {
			Clip = clip;
			Load();
			SwitchOff();
			SetSourceSwitch(true);
			
			Info = new PureDataInfo(pureData.infoManager.GetInfo(clip.Name), pureData);
			State = PureDataStates.Waiting;
			SetPaused(false);
			SetOutput(Info.output);
			SetVolume(Info.volume + Info.volume * HelperFunctions.RandomRange(-Info.randomVolume, Info.randomVolume));
			SetPitch(Info.pitch + Info.pitch * HelperFunctions.RandomRange(-Info.randomPitch, Info.randomPitch));
			SetPlayRange(Info.playRangeStart, Info.playRangeEnd);
			SetFadeIn(Info.fadeIn);
			SetFadeOut(Info.fadeOut);
			SetLoop(Info.loop);
		}
예제 #5
0
 public void Deactivate(PureDataClip clip)
 {
     nameOccurenceDict[clip.Name] -= 1;
 }