Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

[Released] GIS Terrain Loader

Discussion in 'Assets and Asset Store' started by UnityGISTech, Aug 12, 2019.

  1. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    Your File Works great may be you need to just update your GTL to the last version.
    Best Regards

    upload_2022-6-4_1-7-35.png
     
  2. abhishekvj2705

    abhishekvj2705

    Joined:
    Jun 7, 2022
    Posts:
    2
    Hi there I brought your asset today and tried to import a GeoTIFF file by following your
    Download Free GIS Data (DEM-Raster-Vector) guide
    but in the end, even though I followed each step precisely the textures are not loading on the terrain. only the elevation data is being loaded as shown below.

    photo_2022-06-16_18-26-28.jpg

    I am new to the geospatial field and I am doing a project in which I have to generate terrain from the data they provide. image_2022-06-16_18-32-31.png Also these are the files they provided. Is it possible to generate a terrain with these files with this tool thanks a lot. I am using Unity 2022.1.3f1.
     
  3. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    I downloaded Unity 2022.2.0, i tested GTL withing this version and it works well.
    upload_2022-6-16_19-45-26.png

    Maybe there is something wrong with your Textures Tiles (Name Must Be Like "Tile__0__0.jpg").

    Best Regards
     
  4. abhishekvj2705

    abhishekvj2705

    Joined:
    Jun 7, 2022
    Posts:
    2


    Thanks for the update textures works now but one of my tif file is over 2 gb and its not loading.
    Also what all vector data formats are supported to import vector data other than .osm
    Thank You
    Best Regards
     
  5. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Loading a huge Tiff file may crash your memory so becarful.
    You can load osm,shp and gpx.
     
  6. tko13

    tko13

    Joined:
    Oct 16, 2019
    Posts:
    2
    Does the vector data need to be in the WGS84 (EPSG:4326) coordinate system? I have DEM (Tiff) and Vector (SHP) files in TM35 (EPSG:3067) coordinate system and I would like to use them without converting them to WGS 84 (EPSG:4326).

    Converting the coordinates spoils the DEM images by making black spots on the edges (Due to the angle change). Attached converted (TM35 -> WGS84) image examples. DEM and results in Unity.
     

    Attached Files:

    • 1.JPG
      1.JPG
      File size:
      77.5 KB
      Views:
      95
    • 2.JPG
      2.JPG
      File size:
      156.5 KB
      Views:
      96
  7. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    HI THERE,
    To avoid any geo-conversion it is recommanded to project your file to WGS84.
    If you want to use another projection you should customize your geo-conversion script by using Dotspatial lib (exist into the plugins folder).
    For more support, send me your DEM + Vector data.

    Best Regards
     
  8. tko13

    tko13

    Joined:
    Oct 16, 2019
    Posts:
    2
    Hi,

    I followed your instructions to customize projections in Unity (to EPSG:3067). I got DEM data working, but Vector data doesn't load correctly when it is in EPSG:3067. I will send you files if you want to try out.

    I followed your Youtube tutorial how to set up Vector data in QGIS. Road Vectors has custom field: Road: 12122-paallyste2

    DEM and Vectors are in EPSG:3067

    Maybe this download link works too for downloading DEM and vectors: https://www.dropbox.com/s/0otd2wswgi0nriu/Q4122A_3067.zip?dl=0
     
  9. Philkrom

    Philkrom

    Joined:
    Dec 26, 2015
    Posts:
    87
    Hello, I followed your GIS Data Downloader for Unity tutorial
    Using SRTM 90 or 30, it works, but if I use ArcGis 10m I get the following error message in the console.
    Any help mostly welcome !
    Best regards
    Philippe

    Error : Occurred while downloading some files ( failed Url | Check your connexion or Inputs ''System.Net.WebException: The remote server returned an error: (503) Service Unavailable: Back-end server is at capacity.
    at System.Net.HttpWebRequest.GetResponseFromData (System.Net.WebResponseStream stream, System.Threading.CancellationToken cancellationToken) [0x00146] in <6d7c4c8dd3624dc596686fb7270ae1e6>:0
    at System.Net.HttpWebRequest.RunWithTimeoutWorker[T] (System.Threading.Tasks.Task`1[TResult] workerTask, System.Int32 timeout, System.Action abort, System.Func`1[TResult] aborted, System.Threading.CancellationTokenSource cts) [0x000f8] in <6d7c4c8dd3624dc596686fb7270ae1e6>:0
    at System.Net.HttpWebRequest.EndGetResponse (System.IAsyncResult asyncResult) [0x00020] in <6d7c4c8dd3624dc596686fb7270ae1e6>:0
    at System.Net.WebClient.GetWebResponse (System.Net.WebRequest request, System.IAsyncResult result) [0x00000] in <6d7c4c8dd3624dc596686fb7270ae1e6>:0
    at System.Net.WebClient.GetWebResponseTaskAsync (System.Net.WebRequest request) [0x0008d] in <6d7c4c8dd3624dc596686fb7270ae1e6>:0
    at System.Net.WebClient.DownloadBitsAsync (System.Net.WebRequest request, System.IO.Stream writeStream, System.ComponentModel.AsyncOperation asyncOp, System.Action`3[T1,T2,T3] completionDelegate) [0x0008d] in <6d7c4c8dd3624dc596686fb7270ae1e6>:0
    at GISTech.GISDataDownloader.TaskCancellationInternals.CancelWithInternal (System.Threading.Tasks.Task task, System.Threading.CancellationToken cancellationToken, System.Boolean swallowCancellationException) [0x00125] in F:\GTLTest2\Assets\GIS Tech\GIS Data Downloader\Plugins\GISDataDownloaderTaskExtension\TaskCancellationExtension.cs:107
    at GISTech.GISDataDownloader.GISDataDownloaderWebDownloader.DownloadFilesAsync (GISTech.GISDataDownloader.GISDataDownloaderRequestedElement Requestfile, System.Threading.CancellationTokenSource taskSource) [0x003f4] in F:\GTLTest2\Assets\GIS Tech\GIS Data Downloader\Editor\GISDataDownloaderWeb\GISDataDownloaderMultiWebDownloader.cs:260 '')
    UnityEngine.Debug:LogError (object)
    GISTech.GISDataDownloader.GISDataDownloaderWebDownloader/<DownloadFilesAsync>d__31:MoveNext () (at Assets/GIS Tech/GIS Data Downloader/Editor/GISDataDownloaderWeb/GISDataDownloaderMultiWebDownloader.cs:264)
    System.Runtime.CompilerServices.AsyncTaskMethodBuilder:SetException (System.Exception)
    GISTech.GISDataDownloader.TaskCancellationInternals/<CancelWithInternal>d__2:MoveNext () (at Assets/GIS Tech/GIS Data Downloader/Plugins/GISDataDownloaderTaskExtension/TaskCancellationExtension.cs:107)
    UnityEngine.UnitySynchronizationContext:ExecuteTasks ()
     
  10. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    It seems that ArcGIS elevation service is no longer available, use mapbox or SRTM 30 instead.
    Best Regards
     
  11. Philkrom

    Philkrom

    Joined:
    Dec 26, 2015
    Posts:
    87
    Hello
    Thanks for your answer, but srtm30 is not accurate enough for my project. It would be great if you could add IGN 5m provider (or even 1m or lidarHD) , as all the elevation data are free and accessible.
    Best regards
    Philippe
     
  12. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    Elevation 5m or lidar does not cover the all world. Contact me on discord for further discussion about your need.
    Best Regards
     
  13. Good_good

    Good_good

    Joined:
    Dec 1, 2014
    Posts:
    3
    Hi,I want to use it in Android,but when I Build,sometings ware wrong.I work it in Unity2020.3.36
    The Error is
    Assets\SimpleFileBrowser\Scripts\FileBrowser.cs(1207,5): error CS0246: The type or namespace name 'FBPermissionCallbackAndroid' could not be found (are you missing a using directive or an assembly reference?),Idont know how to solve it.
     
  14. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there the current version does not support android and ios.
    Check your email inbox.
    Best Regards
     
  15. vincentgoh82

    vincentgoh82

    Joined:
    Aug 23, 2022
    Posts:
    1
    Tested the example Cuenca but unable to generate the forest from the Vector data(.shp).
    It shows this error:
    InvalidOperationException: Sequence contains no elements
    System.Linq.Enumerable.Min[TSource] (System.Collections.Generic.IEnumerable`1[T] source, System.Func`2[T,TResult] selector) (at <93223d662c2546d4b5d1784737504095>:0)
     
    Last edited: Sep 1, 2022
  16. JL13sky

    JL13sky

    Joined:
    Jun 29, 2022
    Posts:
    3
    hi,the GTL is very useful to load a local GIS data to unity.the Documentation v1.5 shows:
    upload_2022-9-2_9-24-58.png
    and the data needs a fiexed format:
    upload_2022-9-2_9-28-8.png
    but i can't get the similar gis data.The datas I download are like this format:
    upload_2022-9-2_9-30-19.png

    upload_2022-9-2_9-36-57.png
    these datas can't load into unity by GTL.
    So how can I get or translate the datas I downladed into the fiexed format that can be loaded into unity by GTL?
    Or can you send me all the format of gis data demos that the GTL supported?
    Thanks!
     
  17. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    GIS Terrain Loader is able to load Tiff as DEM and Shp file as Vector Data without need to convert to another format.

    Best Regards
     
  18. JL13sky

    JL13sky

    Joined:
    Jun 29, 2022
    Posts:
    3
    thanks!
    But the tiff data and the shp data are not the same area .I can't download a tiff data with a shp data matched it.The gis data I downloaded is a single tiff data or a shp data .like this:
    where can i downlaod the formated data that can load to GTL directly?Or how can i format it with some software?
    thanks again!
     

    Attached Files:

    • world.7z
      File size:
      185.9 KB
      Views:
      59
  19. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    If You Don't have any custom data and no GIS Skills you can use "GIS Data Downloader" which is able to download data Directly on your hard disk then load it to GIS Terrain Loader.
    Link of Data Downloaded via GDD.
     
  20. JL13sky

    JL13sky

    Joined:
    Jun 29, 2022
    Posts:
    3
    THANKS!
     
  21. thomasmorcom

    thomasmorcom

    Joined:
    Aug 29, 2022
    Posts:
    1
    Hi,
    I am having issues when attempting to use OSM data with the loader nothing is generated. Even with the supplied example Cuenca data, none of the OSM data appears, only empty objects are created. Are there particular requirements for using OSM data with the DEM data?
     
  22. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    The example Cuenca works well, maybe there is somethings wrong with your systeme.
    Contact me on discord Chanel i will try to check the source of that issue.
    Best Regards
     
  23. findfix

    findfix

    Joined:
    Sep 19, 2018
    Posts:
    1
    Good morning.
    Firstly, great tool however I am having the same problem as thomasmorcom. I have followed all of the tutorials and am fairly certain that the .shp/.osm files are correct as I have done this process with other softwares. I am receiving no console errors but nothing is being visualised.
    I am producing/creating the .shp in GlobalMapper as there is little .OSM for area I am using. I have exported as both .shp and OSM.
    I am running Unity 2021.3.6f1.
    worst case I can paint the trees but I do need to import building shapes
    cheers
     
  24. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    Thanks for using GTL, please email me (GISTech2008@gmail.com) including your invoice number I'll send you some updated scripts.

    Best Regards.
     
  25. Sankgoku

    Sankgoku

    Joined:
    Nov 22, 2022
    Posts:
    1
    Hi, GISTech
    I'm developing a game which is on real world and realistic terrain.
    I just want to ask your GIS assets provide the actual coordination like latitude and longitude because i want to display there feature on the screen.
     
  26. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there, you can display coordinates and elevation of any point (georeferenced terrain).

    Best regards
     
  27. kt5881

    kt5881

    Joined:
    Jul 26, 2014
    Posts:
    16
    Hi GISTech,

    I have DEM data files, the extension is *.img
    Can I use it on GTL? or I have to change the img extention to something on QGIS?
     
  28. psk131

    psk131

    Joined:
    Aug 19, 2016
    Posts:
    5
    Hi,

    Was this issue ever solved? I have the exact same problem with shapefile in EPSG:3067. The DEM loads after adding the Dotspatial lib but shapefile does not. It fails silently, so this was hard to debug. I tried to solve this for hours and finally tracked the issue to the script "GISTerrainLoaderBuilding.cs" where the for loop between lines 53 and 71 removes all the points from the building so nothing is generated. Could the problem be with the Angle2D function at line 477?

    After I converted all data to WGS84 everything worked. However, I did not see mention in the manual that vector data has to be always in WGS84 format. It is quite confusing because the manual says that support for other coordinate systems can be added with the DotSpatial lib but apparently this is only relevant for DEMs.

    As the other user also said, converting all data to to WGS84 causes other issues with DEMs, especially if you are working with large areas (I have hundreds of tiles). This is a pity, because most other similar tools only support WGS84 but GIS Terrain Loader could also support other coordinate systems. Most other tools are focused on easy and generic use, but GIS Terrain Loader is so far the best solution I have seen for importing custom GIS data from good quality sources to Unity. We have really good open data for the whole country here in Finland but it is in EPSG:3067. Would be perfect if it could be used without reprojection.
     
  29. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    Img files not supported yet, use QGIS to export your dem to GeoTiff file.

    Best Regrades
     
  30. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    Thanks for mentions such a point, by using Dotspatial Lib you will be able to load generate a terrain from different projections that what it was mentioned in docs, but sure vector data works only with WGS 84 EPSG 4326.
    You know that Projections in GIS data is very vast complicated matter and in order to fix that issue i have to change the entire VectorLoader Core.
    i solved this issue in the pro version (released soon) which is an upgrade of GTL.
    The Pro version is able to load all your data with the source projection without any need to GIS software intervention.
    We are doing our best to make that tool more professional and helpful.

    Best Regards
     
  31. psk131

    psk131

    Joined:
    Aug 19, 2016
    Posts:
    5
    Okay, but it says in the asset description that it supports different projections. There is no mention that is applies only to DEMs so it is a bit misleading and should be corrected. I don't mind that so much and I am still happy that I bought the asset because it does some things really well (like a better version of Unity Terrain Tools). However, I lost quite many work hours trying to think what was wrong with my vector data because it did not give any error message. I must say that this asset is not the easiest to use. Even the rather complicated directory system reminds me perhaps too much of GIS world ;) But still, this is my favourite GIS asset in Unity because it supports custom formats.

    Also, I just remembered the open source BlenderGIS can import vector data in pretty much any coordinate system and generates 3D objects from that data so I don't really need this asset for that purpose anymore – although I like how well GIS Terrain Loader does it if the data is in WGS 84. Maybe you are correct that this is mostly a professional thing because these better quality sources are perhaps not so well-known among basic users, so great to hear that there will be also a pro version. However, I have to note that all of this better quality data is open data so it is available for anyone, at least here.
     
  32. craigseaeng

    craigseaeng

    Joined:
    Jan 14, 2022
    Posts:
    2
    Hello!

    Great utility for loading DEMs and tiles. Very clear explanation.

    However, when I load shapefiles for buidings into the '/#filename#_VectorData/SHP Vector data' directory, no file information is loaded and I get an error that there is no *.osm file. I thought I could work with shapefiles only for defining buildings.

    Is there a clear tutorial for creating a building (or other) shapefile and having it load and create buildings?

    Also, could not find you on discord?

    Thanks in advance!

    FOUND SOLUTION:
    It worked when I explicitly created an attrbute in the shapefile named 'building' and then pupulated the value for that attribute for each polygon with a building type from the prefab list (e.g., 'public'). I figured it out after watching the youtube tutorial carefully. Might be nice to write up in the manual as well :)

     
    Last edited: Jan 23, 2023
  33. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there, sorry for being late
    i already uploaded a tutorial which explain how to use QGIS with GTL to import shapefiles.

    Discord link : https://discord.com/invite/3FhNP7YR54
    Best Regards
     
  34. kt5881

    kt5881

    Joined:
    Jul 26, 2014
    Posts:
    16
    Hi UnityGIStech,

    I can use tiff format for DEM.
    you guided shp for Vector data. can I use dxf(vector file format) instead shp?
     
  35. UnityGISTech

    UnityGISTech

    Joined:
    May 6, 2015
    Posts:
    178
    Hi there,
    You can load osm, shp or gpx as vector data dfx not supprted.