Package gov.nasa.worldwind.geom

Examples of gov.nasa.worldwind.geom.Sector


            sb.append("&width=");
            sb.append(tile.getLevel().getTileWidth());
            sb.append("&height=");
            sb.append(tile.getLevel().getTileHeight());

            Sector s = tile.getSector();
            sb.append("&bbox=");
            sb.append(s.getMinLongitude().getDegrees());
            sb.append(",");
            sb.append(s.getMinLatitude().getDegrees());
            sb.append(",");
            sb.append(s.getMaxLongitude().getDegrees());
            sb.append(",");
            sb.append(s.getMaxLatitude().getDegrees());

            sb.append("&format=image/gif");
            sb.append("&version=1.1.1");
            sb.append("&styles=");
View Full Code Here


        WWIO.saveBuffer(byteBuffer, file, forceFilesystemWrite);
    }

    protected void writeWorldFile(AVList values, java.io.File file) throws java.io.IOException
    {
        Sector sector = (Sector) values.getValue(AVKey.SECTOR);
        int[] size = (int[]) values.getValue(WorldFile.WORLD_FILE_IMAGE_SIZE);

        double xPixelSize = sector.getDeltaLonDegrees() / (size[0] - 1);
        double yPixelSize = -sector.getDeltaLatDegrees() / (size[1] - 1);
        double xCoeff = 0.0;
        double yCoeff = 0.0;
        double xLocation = sector.getMinLongitude().degrees;
        double yLocation = sector.getMaxLatitude().degrees;

        java.io.PrintWriter out = new java.io.PrintWriter(file);
        try
        {
            out.println(xPixelSize);
View Full Code Here

        int[] size = new int[2];
        size[0] = raster.getWidth();
        size[1] = raster.getHeight();
        worldFileParams.setValue(WorldFile.WORLD_FILE_IMAGE_SIZE, size);

        Sector sector = raster.getSector();
        worldFileParams.setValue(AVKey.SECTOR, sector);

        worldFileParams.setValue(AVKey.BYTE_ORDER, getByteOrder(byteBufferRaster.getByteBuffer()));
        worldFileParams.setValue(AVKey.PIXEL_FORMAT, AVKey.ELEVATION);
        worldFileParams.setValue(AVKey.DATA_TYPE, getDataType(byteBufferRaster.getBuffer()));
View Full Code Here

       
        this._strId_ = strId;
       
        Position posMin = lstPosition.get(0);
        Position posMax = lstPosition.get(1);
        Sector sec = Sector.boundingSector(posMin, posMax);
        super.setSector(sec);
       
       
       
        setAttributesThis();
View Full Code Here

          Point2D.Double p2dMin = lstP2d.get(0);
          Point2D.Double p2dMax = lstP2d.get(1);

          Position posMin = Position.fromDegrees(p2dMin.y, p2dMin.x);
          Position posMax = Position.fromDegrees(p2dMax.y, p2dMax.x);
          Sector sec = Sector.boundingSector(posMin, posMax);
          super.setSector(sec);
          this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
          return;
       }
      
View Full Code Here


   @Override
   public double getCharacteristicDimensionObjectGeoforgeRenderableLayer() throws Exception
   {
      Sector sec = super.getSector();
     
        Iterator<? extends LatLon> itr = sec.asList().iterator();
       
        if (! itr.hasNext())
        {
            String str = "! itr.hasNext()";
            GfrRndSurfaceSectorTloAbs._LOGGER_.severe(str);
View Full Code Here

   
    @Override
    public Iterable<? extends LatLon> getLocationsRenderableObject()
    {
       SurfaceSector ssr = (SurfaceSector) super._rndObject;
       Sector sec = ssr.getSector();
      
       LatLon llnMin = new LatLon(sec.getMinLatitude(), sec.getMinLongitude());
       LatLon llnMax = new LatLon(sec.getMaxLatitude(), sec.getMaxLongitude());
      
       List<LatLon> lstLatLon = new ArrayList<LatLon>();
       lstLatLon.add(llnMin);
       lstLatLon.add(llnMax);
      
View Full Code Here

            sb.append("&width=");
            sb.append(tile.getWidth());
            sb.append("&height=");
            sb.append(tile.getHeight());

            Sector s = tile.getSector();
            sb.append("&bbox=");
            sb.append(s.getMinLongitude().getDegrees());
            sb.append(",");
            sb.append(s.getMinLatitude().getDegrees());
            sb.append(",");
            sb.append(s.getMaxLongitude().getDegrees());
            sb.append(",");
            sb.append(s.getMaxLatitude().getDegrees());
            sb.append("&"); // terminate the query string

            return new java.net.URL(sb.toString().replace(" ", "%20"));
        }
View Full Code Here

            Logging.logger().severe("WMS.NoImageFormats");
            throw new WWRuntimeException(Logging.getMessage("WMS.NoImageFormats"));
        }

        // Determine bounding sector.
        Sector sector = (Sector) params.getValue(AVKey.SECTOR);
        if (sector == null)
        {
            for (String name : names)
            {
                Sector layerSector = caps.getLayerByName(name).getGeographicBoundingBox();
                if (layerSector == null)
                {
                    Logging.logger().log(java.util.logging.Level.SEVERE, "WMS.NoGeographicBoundingBoxForLayer", name);
                    continue;
                }
View Full Code Here

TOP

Related Classes of gov.nasa.worldwind.geom.Sector

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.