public async Task Handle(MakeTriangulation request)
        {
            var dispatcher = request.Dispatcher;
            var log        = request.Log;
            var points     = request.Points;

            log.Info("Calculating");

            ITriangulationAlgorithm algorythm = new BowyerWatsonAlgorithm();

            var triangles = algorythm.Calculate(points);

            log.Info("Calculated");

            var composite = request.Composite;

            var totalCount = triangles.Count;
            var drawnCount = 0;

            log.Info($"{drawnCount}/{totalCount}");

            foreach (var triangle in triangles)
            {
                await this.AddLines(
                    dispatcher,
                    composite,
                    Brushes.PaleVioletRed,
                    new double[3, 4]
                {
                    { triangle.P1.X, triangle.P1.Y, triangle.P2.X, triangle.P2.Y },
                    { triangle.P2.X, triangle.P2.Y, triangle.P3.X, triangle.P3.Y },
                    { triangle.P3.X, triangle.P3.Y, triangle.P1.X, triangle.P1.Y }
                }
                    );

                drawnCount++;

                if (drawnCount % 10 == 0)
                {
                    log.Info($"{drawnCount}/{totalCount}");
                }
            }

            log.Info($"{drawnCount}/{totalCount}");
        }
        public async Task Handle(MakeMultiColorTriangulation request)
        {
            var dispatcher = request.Dispatcher;
            var log        = request.Log;
            var points     = request.Categories.SelectMany(e => e.Value).ToList();

            log.Info("Calculating");

            ITriangulationAlgorithm algorythm = new BowyerWatsonAlgorithm();

            var triangles = algorythm.Calculate(points);

            log.Info("Calculated");

            var composite = request.Composite;

            var totalCount = triangles.Count;
            var drawnCount = 0;

            log.Info($"{drawnCount}/{totalCount}");

            foreach (var triangle in triangles)
            {
                Brush          f1b = null;
                Brush          f2b = null;
                Brush          f3b = null;
                Diagrams.Point p1  = null;
                Diagrams.Point p2  = null;
                Diagrams.Point p3  = null;

                foreach (var category in request.Categories)
                {
                    foreach (var point in category.Value)
                    {
                        if (point.X == triangle.P1.X && point.Y == triangle.P1.Y)
                        {
                            p1  = point;
                            f1b = category.Key;

                            if (f2b != null && f3b != null)
                            {
                                break;
                            }
                        }
                        else if (point.X == triangle.P2.X && point.Y == triangle.P2.Y)
                        {
                            p2  = point;
                            f2b = category.Key;

                            if (f1b != null && f3b != null)
                            {
                                break;
                            }
                        }
                        else if (point.X == triangle.P3.X && point.Y == triangle.P3.Y)
                        {
                            p3  = point;
                            f3b = category.Key;

                            if (f1b != null && f2b != null)
                            {
                                break;
                            }
                        }
                    }

                    if (f1b != null && f2b != null && f3b != null)
                    {
                        break;
                    }
                }

                await this.DrawEdge(dispatcher, composite, f1b, p1, f2b, p2);

                await this.DrawEdge(dispatcher, composite, f2b, p2, f3b, p3);

                await this.DrawEdge(dispatcher, composite, f1b, p1, f3b, p3);

                drawnCount++;

                if (drawnCount % 10 == 0)
                {
                    log.Info($"{drawnCount}/{totalCount}");
                }
            }

            log.Info($"{drawnCount}/{totalCount}");
        }