Examples of intersects()


Examples of com.vividsolutions.jts.geom.MultiPolygon.intersects()

            // take the part that intersects with the start vertex
            Coordinate startCoordinate = startEndpoint.getCoordinate();
            Point startPoint = geometryFactory.createPoint(startCoordinate);
            for (Area area : intersects) {
                MultiPolygon polygon = area.toJTSMultiPolygon();
                if (!(polygon.intersects(startPoint) || polygon.getBoundary()
                        .intersects(startPoint)))
                    continue;
                Geometry lineParts = line.intersection(polygon);
                if (lineParts.getLength() > 0.000001) {
                    Coordinate edgeCoordinate = null;
View Full Code Here

Examples of com.vividsolutions.jts.geom.Point.intersects()

    assertEquals(false, p1.contains(p2));
    assertEquals(false, p1.overlaps(p2));

    assertEquals(false, p2.equals(p1));
    assertEquals(true, p2.disjoint(p1));
    assertEquals(false, p2.intersects(p1));
    assertEquals(false, p2.touches(p1));
    assertEquals(false, p2.crosses(p1));
    assertEquals(false, p2.within(p1));
    assertEquals(false, p2.contains(p1));
    assertEquals(false, p2.overlaps(p1));
View Full Code Here

Examples of com.vividsolutions.jts.geom.prep.PreparedGeometry.intersects()

  {
    public static boolean intersects(Geometry g1, Geometry g2)
    {
      PreparedGeometryFactory pgFact = new PreparedGeometryFactory();
      PreparedGeometry prepGeom = pgFact.create(g1);
      return prepGeom.intersects(g2);
    }
    public static boolean contains(Geometry g1, Geometry g2)
    {
      PreparedGeometryFactory pgFact = new PreparedGeometryFactory();
      PreparedGeometry prepGeom = pgFact.create(g1);
View Full Code Here

Examples of com.vividsolutions.jts.geom.prep.PreparedPolygon.intersects()

                    for (final Object o : spatialIndex.query(p
                            .getEnvelopeInternal())) {
                        SimpleFeature f = (SimpleFeature) o;
                        Geometry g = ((Geometry) f.getAttribute(geomName));
                        if (ppoly.intersects(g)) {
                            // logger.debug("***************************");
                            // logger.debug(p.toString());
                            // logger.debug(g.toString());
                            Geometry geom = p.intersection(g);
                            // logger.debug(geom.toString());
View Full Code Here

Examples of eas.math.geometry.LineSegment2D.intersects()

                    zwischPunkte.get(1));
            q = new LineSegment2D(
                    pktList1.get(pktList1.nPoints() - 1),
                    pktList2.get(pktList2.nPoints() - 1));
           
            if (p.intersects(q) == null) {
                pktList1.add(zwischPunkte.get(0));
                pktList2.add(zwischPunkte.get(1));
            } else {
                StaticMethods.log(StaticMethods.LOG_WARNING,
                              "Segment konnte nicht überschneidungsfrei "
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.ast.Sig.PrimSig.intersects()

            nodes.add(a);
            nodes.add(b);
            graph.addEdge(a,b);
        }
        // For each distinct v1 and v2 in the graph where v1&v2!=empty, add the edges v1->v2 and v2->v1.
        for (PrimSig a:nodes) for (PrimSig b:nodes) if (a!=b && a.intersects(b)) graph.addEdge(a,b);
        // For each a->b in ParentType:
        // 1) add a
        // 2) add b
        // 3) if a has subtypes/supertypes in the graph, connect between a and them.
        // 4) if b has subtypes/supertypes in the graph, connect between b and them.
View Full Code Here

Examples of gistoolkit.features.Envelope.intersects()

                       
                        // loop through the images attempting to find the right one.
                        for (int l=0; l<mySourceList.size(); l++){
                            if (myStopProcessing) return;
                            ImageTile tempTile = (ImageTile) mySourceList.get(l);
                            if (tempTileEnvelope.intersects(tempTile.getEnvelope())){
                                System.out.println("ImageEnvelope = "+tempTile.getEnvelope());
                               
                                // draw this tile on the buffer.
                                Envelope tempNewEnvelope = tempTileEnvelope.getOverlap(tempTile.getEnvelope());
                               
View Full Code Here

Examples of gov.nasa.worldwind.geom.Cylinder.intersects()

      if (f.contains(ptC))
         return true;

      double r = Line.distanceToSegment(ptA, ptB, ptC);
      Cylinder cyl = new Cylinder(ptA, ptB, r == 0 ? 1 : r);
      return cyl.intersects(dc.getView().getFrustumInModelCoordinates());
   }

   protected Vec4 computePoint(DrawContext dc, Position pos, boolean applyOffset)
   {
      if (this.followTerrain)
View Full Code Here

Examples of java.awt.Rectangle.intersects()

          if ((i + 1) < blockArr.length) {
            maxY = blockArr[i + 1].mStartY;
          } else {
            maxY = height;
          }
          if (!clipBounds.intersects(0, minY, width, maxY - minY)) {
            // this piece is not visible at all
            continue;
          }

          // Get the image of this time block
View Full Code Here

Examples of java.awt.Shape.intersects()

            overall.height += 1;
           
            Rectangle bounds = new Rectangle(overall);
            bounds.width += 1;
            bounds.height += 1;
            if (working.intersects(bounds)) {
                page.paintBackground(c, pagePaintingClearanceWidth, Layer.PAGED_MODE_SCREEN);
                page.paintMarginAreas(c, pagePaintingClearanceWidth, Layer.PAGED_MODE_SCREEN);
                page.paintBorder(c, pagePaintingClearanceWidth, Layer.PAGED_MODE_SCREEN);
               
                Color old = g.getColor();
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.