コード例 #1
0
ファイル: EdgeSetNoder.cs プロジェクト: carlhuth/GenXSource
        }         // public void AddEdges(ArrayList edges)

        /// <summary>
        ///
        /// </summary>
        /// <returns></returns>
        public ArrayList GetNodedEdges()
        {
            EdgeSetIntersector esi = new SimpleMCSweepLineIntersector();
            SegmentIntersector si  = new SegmentIntersector(_li, true, false);

            esi.ComputeIntersections(_inputEdges, si);
            //Trace.WriteLine("has proper int = " + si.hasProperIntersection());

            ArrayList splitEdges = new ArrayList();

            foreach (object obj in _inputEdges)
            {
                Edge e = (Edge)obj;
                e.EdgeIntersectionList.AddSplitEdges(splitEdges);
            }
            return(splitEdges);
        }         // public ArrayList GetNodedEdges()
コード例 #2
0
ファイル: GeometryGraph.cs プロジェクト: tinuvieltr/geotools
        }         // public SegmentIntersector computeSelfNodes(LineIntersector li)

        /// <summary>
        ///
        /// </summary>
        /// <param name="g"></param>
        /// <param name="li"></param>
        /// <param name="includeProper"></param>
        /// <returns></returns>
        public SegmentIntersector ComputeEdgeIntersections(
            GeometryGraph g,
            LineIntersector li,
            bool includeProper)
        {
            SegmentIntersector si = new SegmentIntersector(li, includeProper, true);

            si.SetBoundaryNodes(GetBoundaryNodes(), g.GetBoundaryNodes());

            EdgeSetIntersector esi = new SimpleMCSweepLineIntersector();

            esi.ComputeIntersections(_edges, g.Edges, si);

            /*
             * foreach ( object obj in g )
             * {
             *      Edge e = (Edge) obj;
             *      Trace.WriteLine( e.EdgeIntersectionList.ToString() );
             * }
             */
            return(si);
        }         // public SegmentIntersector ComputeEdgeIntersections(...