/// <summary>
        /// Transport data between two BlockingCollection
        /// </summary>
        /// <param name="threadInfos">Object who contains the data to be tranfered </param>
        override protected void Launch(object threadInfos)
        {
            MiddleThreadInfos <Skeleton> ti = (MiddleThreadInfos <Skeleton>)threadInfos;

            Console.WriteLine("TransformationSkeleton thread started");

            while (true)
            {
                var data = ti._udpToMiddle.Take();
                ti._middleToWebRtc.Add(data);
            }
        }
        private void StartProsecute(object threadInfos)
        {
            MiddleThreadInfos ti = (MiddleThreadInfos)threadInfos;

            Console.WriteLine("Thread middle démarrée");

            while (true)
            {
                if (ti._udpToMiddle.IsEmpty())
                {
                    Thread.Sleep(1000);
                }
                else
                {
                    ti._middleToWebRtc.AddData(ti._udpToMiddle.ConsumeData());
                    Console.WriteLine("Transfert");
                }
            }
        }
 public TransformationSkeletonService(BlockingCollection <Skeleton> udpToMiddle, BlockingCollection <Skeleton> middleToWebRtc)
 {
     _middleThreadInfos = new MiddleThreadInfos <Skeleton>(udpToMiddle, middleToWebRtc);
 }
 public TransformationService(DataTransferer udpToMiddle, DataTransferer middleToWebRtc)
 {
     _middleThreadInfos = new MiddleThreadInfos(udpToMiddle, middleToWebRtc);
 }