Package com.vividsolutions.jts.geom

Examples of com.vividsolutions.jts.geom.GeometryCollection.convexHull()


        for (GCodeCommand c : commands) {
            if(c.type == GCodeCommand.Type.MOVE)
                pList.add(JTSUtils.createPoint2D(c.x, c.y));
        }
        GeometryCollection g = new GeometryCollection(pList.toArray(new Point[pList.size()]), JTSUtils.getFactory());
        return g.convexHull();
    }
   
    /**
     *
     * @return a deep copy of this snippet
View Full Code Here


                    // (see wikipedia: http://en.wikipedia.org/wiki/Latitude#The_length_of_a_degree_of_latitude)
                    try {
                        ConcaveHull hull = new ConcaveHull(gc, concaveHullAlpha);
                        outputHull = hull.getConcaveHull();
                    } catch (Exception e) {
                        outputHull = gc.convexHull();
                        LOG.debug("Could not generate ConcaveHull for WalkShed, using ConvexHull instead.");
                    }
                    LOG.debug("write shed geom");
                    geometryJSON.write(outputHull, sw);
                    LOG.debug("done");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.