public GlobeTile CreateTile(Transform parent, Wmts coords) { GameObject tileGo = Instantiate(tileTemplate); tileGo.transform.SetParentClearRelativeTransform(parent); tileGo.name = coords.ToString(); GlobeTile tile = tileGo.GetComponent <GlobeTile>(); tile.coords = coords; tile.globe = globe; tile.bBox = Layer.Wmts2DefaultBbox(coords); tile.SetVisible(false); return(tile); }
private void CreateTile(GlobeTile parent, Wmts coords) { GameObject tileGo = Instantiate(tileTemplate); tileGo.transform.SetParentClearRelativeTransform(parent.transform); tileGo.name = coords.ToString(); GlobeTile tile = tileGo.GetComponent <GlobeTile>(); tile.coords = coords; tile.globe = globe; tile.bBox = globe.CurrentLayer.Wmts2Bbox(coords); tile.SetVisible(false); parent.AddChild(tile); }