NearestEdge() private method

private NearestEdge ( ) : Edge
return Edge
示例#1
0
        public List <Circle> Circles()
        {
            List <Circle> list = new List <Circle>();

            for (int i = 0; i < _sites.Count; i++)
            {
                Site  site   = _sites[i];
                float radius = 0f;
                Edge  edge   = site.NearestEdge();
                if (!edge.IsPartOfConvexHull())
                {
                    radius = edge.SitesDistance() * 0.5f;
                }
                list.Add(new Circle(site.x, site.y, radius));
            }
            return(list);
        }