Ejemplo n.º 1
0
 /// <summary>
 /// Adds a source/sink combination to this muxer
 /// </summary>
 /// <param name="source"></param>
 /// <param name="sink"></param>
 public PushPullObject AddInputOutputSource(IAudioSource source, IAudioSink sink)
 {
     PushPullObject member = new PushPullObject(source, sink);
     lock (MemberLock)
     {
         Members.Add(member);
     }
     return member;
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Adds a source/sink combination to this muxer
        /// </summary>
        /// <param name="source"></param>
        /// <param name="sink"></param>
        public PushPullObject AddInputOutputSource(IAudioSource source, IAudioSink sink)
        {
            PushPullObject member = new PushPullObject(source, sink);

            lock (MemberLock)
            {
                Members.Add(member);
            }
            return(member);
        }
Ejemplo n.º 3
0
        public void RemoveInputOutputSource(IAudioSource source, IAudioSink sink)
        {
            lock (MemberLock)
            {
                PushPullObject removeobject = null;
                foreach (PushPullObject ppo in Members)
                {
                    if ((ppo.AudioSource == source) && (ppo.AudioSink == sink))
                    {
                        removeobject = ppo;
                        break;
                    }
                }

                if (removeobject != null)
                {
                    Members.Remove(removeobject);
                }
            }
        }