All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.meteoinfo.data.mapdata.webmap.OviSatelliteMapInfo Maven / Gradle / Ivy

There is a newer version: 3.8
Show newest version
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.meteoinfo.data.mapdata.webmap;

/**
 *
 * @author yaqiang
 */
public class OviSatelliteMapInfo extends TileFactoryInfo {
    // 
    protected final String[] urlServerLetters = new String[]{"b", "c", "d", "e"};
    // 
    // 

    /**
     * Constructor
     */
    public OviSatelliteMapInfo() {
        super("OviSatelliteMap", 1, 17, 19,
                256, true, true, // tile size is 256 and x/y orientation is normal
                "http://%1$s.maptile.maps.svc.ovi.com/maptiler/v2/maptile/newest/satellite.day/%2$d/%3$d/%4$d/256/png8",//5/15/10.png",
                "x", "y", "z");
    }
//    // 
//    // 
//    // 
//    // 

    @Override
    public String getTileUrl(int x, int y, int zoom) {
        zoom = this.getTotalMapZoom() - zoom;
        int serverNum = this.getServerNum(x, y, 3) + 1;
        String url = String.format(this.baseURL, urlServerLetters[serverNum], zoom, x, y);
        return url;
    }
    // 
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy