Package com.vividsolutions.jts.triangulate.quadedge

Examples of com.vividsolutions.jts.triangulate.quadedge.QuadEdgeSubdivision


  /**
   * Computes the Delaunay triangulation of the initial sites.
   */
  public void formInitialDelaunay() {
    computeBoundingBox();
    subdiv = new QuadEdgeSubdivision(computeAreaEnv, tolerance);
    subdiv.setLocator(new LastFoundQuadEdgeLocator(subdiv));
    incDel = new IncrementalDelaunayTriangulator(subdiv);
    insertSites(initialVertices);
  }
View Full Code Here


  /**
   * Computes the Delaunay triangulation of the initial sites.
   */
  public void formInitialDelaunay() {
    computeBoundingBox();
    subdiv = new QuadEdgeSubdivision(computeAreaEnv, tolerance);
    subdiv.setLocator(new LastFoundQuadEdgeLocator(subdiv));
    incDel = new IncrementalDelaunayTriangulator(subdiv);
    insertSites(initialVertices);
  }
View Full Code Here

    ConformingDelaunayTriangulationBuilder cdtb = new ConformingDelaunayTriangulationBuilder();

    // add geometry collection
    cdtb.setSites(this.geometries);
   
    QuadEdgeSubdivision qes = cdtb.getSubdivision();
   
    Collection<QuadEdge> quadEdges = qes.getEdges();
    List<QuadEdgeTriangle> qeTriangles = QuadEdgeTriangle.createOn(qes);
    Collection<com.vividsolutions.jts.triangulate.quadedge.Vertex> qeVertices =
      qes.getVertices(false);
   
    int iV = 0;
    for (com.vividsolutions.jts.triangulate.quadedge.Vertex v : qeVertices) {
      this.coordinates.put(v.getCoordinate(), iV);
      this.vertices.put(iV, new Vertex(iV, v.getCoordinate()));
      iV++;
    }
   
    // border
    List<QuadEdge> qeFrameBorder = new ArrayList<QuadEdge>();
    List<QuadEdge> qeFrame = new ArrayList<QuadEdge>();
    List<QuadEdge> qeBorder = new ArrayList<QuadEdge>();

    for (QuadEdge qe : quadEdges) {
      if (qes.isFrameBorderEdge(qe)) {
        qeFrameBorder.add(qe);
      }
      if (qes.isFrameEdge(qe)) {
        qeFrame.add(qe);
      }
    }

    // border
    for (int j = 0 ; j < qeFrameBorder.size() ; j++) {
      QuadEdge q = qeFrameBorder.get(j);
      if (! qeFrame.contains(q)) {
        qeBorder.add(q);
      }
    }
   
    // deletion of exterior edges
    for (QuadEdge qe : qeFrame) {
      qes.delete(qe);
    }
   
    HashMap<QuadEdge, Double> qeDistances = new HashMap<QuadEdge, Double>();
    for (QuadEdge qe : quadEdges) {
      qeDistances.put(qe, qe.toLineSegment().getLength());
View Full Code Here

TOP

Related Classes of com.vividsolutions.jts.triangulate.quadedge.QuadEdgeSubdivision

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.