One Paragraph of project description goes here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
// LoadingScreenManager | |
// -------------------------------- | |
// built by Martin Nerurkar (http://www.martin.nerurkar.de) | |
// for Nowhere Prophet (http://www.noprophet.com) | |
// | |
// Licensed under GNU General Public License v3.0 | |
// http://www.gnu.org/licenses/gpl-3.0.txt | |
using UnityEngine; | |
using UnityEngine.UI; |
using UnityEngine; | |
using System.Collections; | |
public class MapUtils { | |
static float GOOGLEOFFSET = 268435456f; | |
static float GOOGLEOFFSET_RADIUS = 85445659.44705395f;//GOOGLEOFFSET / Mathf.PI; | |
static float MATHPI_180 = Mathf.PI/180f; | |
static private float preLonToX1 = GOOGLEOFFSET_RADIUS * (Mathf.PI/180f); |
using UnityEngine; | |
using System.Collections; | |
public class MeshPixelTools : MonoBehaviour { | |
// Use this for initialization | |
void Start () { | |
} | |
pixelToPoint = function(point, zoom, center, bounds) { | |
// 像素到坐标 | |
if (!point) { | |
return | |
} | |
var zoomUnits = getZoomUnits(zoom); | |
var mercatorLng = center.lng + zoomUnits * (point.x - bounds.width / 2); | |
var mercatorLat = center.lat - zoomUnits * (point.y - bounds.height / 2); | |
var mercatorLngLat = {lng: mercatorLng, lat: mercatorLat}; | |
return mercatorToLngLat(mercatorLngLat) |