Examples of AxisAlignedBoundingBoxXZ


Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

 
  private final IntersectionGrid<MapElement> intersectionGrid;
     
  public MapIntersectionGrid(AxisAlignedBoundingBoxXZ dataBoundary) {
   
    AxisAlignedBoundingBoxXZ gridBounds = dataBoundary.pad(10);
   
    intersectionGrid = new IntersectionGrid<MapElement>(
        gridBounds,
        gridBounds.sizeX() / 50,
        gridBounds.sizeZ() / 50);
   
  }
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

      return GroundState.ON;
    }
   
    @Override
    public AxisAlignedBoundingBoxXZ getAxisAlignedBoundingBoxXZ() {
      return new AxisAlignedBoundingBoxXZ(Collections.singleton(node.getPos()));
    }
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

  public Collection<Collection<T>> cellsFor(
      IntersectionTestObject object) {

    assert(gridBounds.contains(object));

    AxisAlignedBoundingBoxXZ objectAABB = object.getAxisAlignedBoundingBoxXZ();
   
    int minCellX = cellXForCoord(objectAABB.minX, objectAABB.minZ);
    int minCellZ = cellZForCoord(objectAABB.minX, objectAABB.minZ);
    int maxCellX = cellXForCoord(objectAABB.maxX, objectAABB.maxZ);
    int maxCellZ = cellZForCoord(objectAABB.maxX, objectAABB.maxZ);
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

 
  public void insert(T object) {
   
    assert(gridBounds.contains(object));
   
    AxisAlignedBoundingBoxXZ objectAABB = object.getAxisAlignedBoundingBoxXZ();
   
    int minCellX = cellXForCoord(objectAABB.minX, objectAABB.minZ);
    int minCellZ = cellZForCoord(objectAABB.minX, objectAABB.minZ);
    int maxCellX = cellXForCoord(objectAABB.maxX, objectAABB.maxZ);
    int maxCellZ = cellZForCoord(objectAABB.maxX, objectAABB.maxZ);
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

 
  public void remove(T object) {
   
    assert(gridBounds.contains(object));
   
    AxisAlignedBoundingBoxXZ objectAABB = object.getAxisAlignedBoundingBoxXZ();
   
    int minCellX = cellXForCoord(objectAABB.minX, objectAABB.minZ);
    int minCellZ = cellZForCoord(objectAABB.minX, objectAABB.minZ);
    int maxCellX = cellXForCoord(objectAABB.maxX, objectAABB.maxZ);
    int maxCellZ = cellZForCoord(objectAABB.maxX, objectAABB.maxZ);
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

  public void defineEleConstraints(EleConstraintEnforcer enforcer) {}
 
  @Override
  public AxisAlignedBoundingBoxXZ getAxisAlignedBoundingBoxXZ() {
    if (getOutlinePolygonXZ() != null) {
      return new AxisAlignedBoundingBoxXZ(
          getOutlinePolygonXZ().getVertexCollection());
    } else {
      return new AxisAlignedBoundingBoxXZ(
          node.getPos().x, node.getPos().z,
          node.getPos().x, node.getPos().z);
    }
  }
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

  public void setKnownSites(Collection<VectorXYZ> sites) {
   
    this.sites = sites;
   
    siteGrid = new IntersectionGrid<VectorXYZ>(
        new AxisAlignedBoundingBoxXZ(sites).pad(CUTOFF/2),
        CUTOFF, CUTOFF);
   
    for (VectorXYZ site : sites) {
      siteGrid.insert(site);
    }
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

    return segment.getEndNode().getPos();
  }
 
  @Override
  public AxisAlignedBoundingBoxXZ getAxisAlignedBoundingBoxXZ() {
    return new AxisAlignedBoundingBoxXZ(asList(
        getStartPosition(), getEndPosition()));
  }
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

      for (MapNode n : closedNodeSequence) {
        minX = min(minX, n.getPos().x); minZ = min(minZ, n.getPos().z);
        maxX = max(maxX, n.getPos().x); maxZ = max(maxZ, n.getPos().z);
      }
     
      return new AxisAlignedBoundingBoxXZ(minX, minZ, maxX, maxZ);
     
    }
View Full Code Here

Examples of org.osm2world.core.math.AxisAlignedBoundingBoxXZ

    return overlaps;
  }

  @Override
  public AxisAlignedBoundingBoxXZ getAxisAlignedBoundingBoxXZ() {
    return new AxisAlignedBoundingBoxXZ(getOuterPolygon().getVertexCollection());
  }
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.