Ejemplo n.º 1
0
        private void ShowOnlyPoints_Click(object sender, RoutedEventArgs e)
        {
            if (mid_surface_model == null)
            {
                return;
            }

            var             segments    = mid_surface_model.GetData();
            List <ISegment> only_points = new List <ISegment>();

            foreach (var segment in segments)
            {
                ISegment point = new Segment(new BezierCurve(), new List <Point>()
                {
                    segment.GetPillar()[0],
                    Vector.Add(new Vector(1, 0), segment.GetPillar()[0])
                });
                only_points.Add(point);
            }

            IMidSurface points_surface = new MidSurface();

            foreach (var point in only_points)
            {
                points_surface.Add(point);
            }
            mainCanvas.Children.Clear();
            RedrawModel();
            View.VisibleDataSettings settings = new View.VisibleDataSettings();
            settings.Brush    = Brushes.Red;
            settings.Thikness = 2;
            View.VisibleData visible_data = new View.VisibleData(points_surface, settings);
            view.Paint(visible_data);
        }
Ejemplo n.º 2
0
 public VisibleData(IMidSurface midsurface, VisibleDataSettings settings)
 {
     segments      = midsurface.GetData().ToList <ISegment>();
     this.settings = settings;
 }
Ejemplo n.º 3
0
 public VisibleData(IMidSurface midsurface) : this()
 {
     segments = midsurface.GetData().ToList <ISegment>();
 }