Package org.openstreetmap.josm.tools.Geometry

Examples of org.openstreetmap.josm.tools.Geometry.PolygonIntersection


        @Override
        public Boolean get(BBox box) {
            Area abox = new Area(box.toRectangle());
            for (Area a : leftHandTrafficPolygons) {
                PolygonIntersection is = Geometry.polygonIntersection(abox, a, 1e-10 /* using deg and not meters */);
                if (is == PolygonIntersection.FIRST_INSIDE_SECOND)
                    return true;
                if (is != PolygonIntersection.OUTSIDE)
                    return null;
            }
View Full Code Here


            for (JoinedPolygon innerWay : boundaryWays) {
                if (innerWay == outerWay) {
                    continue;
                }

                PolygonIntersection intersection = Geometry.polygonIntersection(outerWay.area, innerWay.area);

                if (intersection == PolygonIntersection.FIRST_INSIDE_SECOND) {
                    outerGood = false// outer is inside another polygon
                    break;
                } else if (intersection == PolygonIntersection.SECOND_INSIDE_FIRST) {
View Full Code Here

TOP

Related Classes of org.openstreetmap.josm.tools.Geometry.PolygonIntersection

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.