Beispiel #1
0
        public void link_overlap(Edge_Factory ef, Measure m)
        {
            int hi = 0;
            int ti = 0;

            while (hi < vertex_count && ti < m.vertex_count)
            {
                Vertex here  = vertices[hi];
                Vertex there = m.vertices[ti];

                if (here.overlap(there))
                {
                    ef.make_edge(here, there);
                }

                if (here.end() + 0.001 < there.end())
                {
                    hi++;
                }
                else if (there.end() + 0.001 < here.end())
                {
                    ti++;
                }
                else
                {
                    ti++;
                    hi++;
                }
            }
        }
Beispiel #2
0
        public bool overlap(Vertex v)
        {
            if (end() + 0.001 < v.start)
            {
                return(false);
            }

            if (v.end() + 0.001 < start)
            {
                return(false);
            }

            return(true);
        }