示例#1
0
    APICalls()
    {
        Debug.Log("API Calls being made");
        osmMapData = await Task.Run(() => api.GetOsmMap());   //working

        mapBounds = await Task.Run(() => api.GetMapBounds()); //working

        Debug.Log("Datapoint getting");
        dataPointId = await Task.Run(() => api.GetPointLocations());

        models = await Task.Run(() => api.GetModels());

        try
        {
            histMapContainer = api.GetHistMap();
            historyMapData   = histMapContainer.MapData;
            historyMap       = gWorld.LoadDataIntoTexture(historyMapData);
        }
        catch (Exception e)
        {
            Debug.Log("Historical map not found: " + e);
            // This means there was no historical map in the db
        }
        goForApi = true;
    }
示例#2
0
 public DataPointInfo(double id, string description, byte[] texture, float lng, float lat)
 {
     Id = id;
     PointDescription          = description;
     PointImage                = gWorld.LoadDataIntoTexture(texture);
     ImageMaterial.mainTexture = PointImage;
     Longitude = lng;
     Latitude  = lat;
 }