====== ArmA 3 Terra Incognita ======
[[https://www.pmctactical.org/forum/viewforum.php?f=68|ArmA 3 Forum]], [[:arma3|ArmA 3]], [[arma3:config|ArmA 3 Config]], [[arma3:missions|ArmA 3 Missions]], [[arma3:modeling|ArmA 3 3D Modeling]], [[arma3:scripting|ArmA 3 Scripting]], [[arma3:terrain|ArmA 3 Terrain]], [[arma3:texturing|ArmA 3 Texturing]], [[arma3:tools|ArmA 3 Tools]]
**How to download high resolution satellite texture with Terra Incognita.**
====== Terra Incognita Download ======
Source **SOURCEFORGE.NET - be warned!** [[https://sourceforge.net/p/terraincognita2/wiki/Home/|sourceforge.net/p/terraincognita2]].
If you browse to [[https://sourceforge.net/projects/terraincognita2/files/|sourceforge.net/projects/terraincognita2/files/]] you'll find ZIP files in there like the moment of writing this tutorial "TerraIncognita241_net4.zip", this is a portable version, meaning you do not have to use the stupid terra incognita .bat installer which forces install dir to your desktop (sigh).
====== Settings ======
**Cache**
Settings -> general -> cache path, this is good to move into some drive that has gigabytes of free space as you will be browsing / downloading satellites so Terra Incognita will be creating a lot of cache files (assuming you are using it, a lot heh).
If you run system drive C: with SSD, then I would recommend moving it to some non system drive as there definitely will be hundreds of thousands of files in several gigabytes after you have used it a lot. Unless you have really large SSD which you specifically want to use for such heavy activities like handling large image cache files.
Default cache dir is
C:\Users\YOURNAME\AppData\Local\TerraIncognita\Cache
Terra Incognita crashes if you try to use two of them at the same time, it happens when they move the cache directory. So unlike global mapper, you cannot run two instances of terra incognita at the same time.
**Deleting Cache Files**
This is recommended to do from windows explorer while terra incognita is not running, but you can also do this from map source -> clear cache.
We don't have conclusive testing results if its a must to delete cache files regularly, but if you do not delete cache then terra incognita will move 10,000 files when such number is reached and you are about to start new download, this can cause huge slowdowns.
If anyone wants to share their experiences with cache files please do.
**OziExplorer as TIF**
File -> Settings -> OziExplorer map (save): saving images as TIF makes it much quicker downloads, apparently as it does not spend time compressing the JPG its that much faster. But in the end part it slowed down, no idea why. **TIF IMAGES ARE HUGE, USE JPG INSTEAD.**
**JPEG Quality**
Settings -> OziExplorer -> Jpged quality, (default is 85), this you should increase from 85 to 100, just to make sure you are not losing any satellite image quality on the download.
However if you increase it to 100 then the exported jpg image size grows from about 10 to 40 megabytes, but prolly have no quality loss indeed.
Perhaps value of 95 might be good compromise for arma3 satellite texture images.
====== Overview ======
When you save large satellite texture in oziexplorer format, Terra Incognita automatically splits it up to smaller .MAP tile files. You can open these .map files with [[arma3:terrain:qgis-real-world-data|QGIS]] or [[arma3:terrain:real-world-data-global-mapper|Global Mapper]].
There are many image sources to choose from but ArcGIS World Imagery is clearly the best.
Use maps.google 100m zoom level (1m / pixel) or ArcGIS 17 (1m / pixel) zoom level to achieve good results for arma3 satellite texture scale. Note: ArcGIS zoom levels are actually 0.8m/px for 17 and 1.6m/px for 16, but when exporting satellite with global mapper you can choose the exact resolution for terrain builder use.
Unlike some other software *cough* universal maps downloader *cough* you wont get any problems with google banning your IP for 24hrs because you download too much. We have been downloading huge 150,000 resolution satellite images for days in row and no problems.
====== Satellite Texture ======
Ice: Also in TerraIncognita zoom right in so it says 1m\px or something right at top of your screen, then export your image as OziExplorer, import that to GM and it will place it exact over your height map
Select map source -> maps.google.com -> google satellite map.
Ice: if you don't have any map source the .dll may be blocked. So you have to unblock it like you would with the x-cams one
Use mouse wheel to zoom in / out of the globe map, LMB drag to move the globe map.
Once you have found a nice area you want to save as satellite texture, use menu selection -> rectangle selection, now you did not see any difference in your mouse cursor but you can LMB drag a box in the globe map. This is your selected area.
Apparently there is no way to make perfect square, power of two selection as you are doing it freehand, if anyone knows a way please let us know.
You can move the selection if you LMB inside the red rectangle and drag. If you LMB drag outside the rectangle you will make a new selection losing the old one.
Please be careful when making a selection, try to visualize how large it is, you can easily make larger than 40960 x 40960 resolution images which has been the largest we have been able to import into photoshop. It is easy to just choose "cool looking area" and then it turns out to be 200k x 200k resolution, yikes! :)
When you are ready, use mouse wheel to zoom IN until the header says (1m/px) resolution. Now use file -> save map -> oziexplorer map, to save your selected satellite texture.
Once downloading there is no abort button, you just have to close terra incognita if you wish to abort your download.
Terra Incognita doesn't appear to have any kind of save project feature, but on restart it does open the last location you had on previous session.
You can use QGIS (or Global Mapper) to open oziexplorer .map files.
QGIS layer -> add layers -> add raster layer, choose pcraster .map and select your terra incognita saved oziexplorer .map file. appears in QGIS main view OK.
**ArcGIS** is world imagery and very good quality satellite texture source.
ArcGIS zoom level 16 is 1.689036m/px and level 17 is 0.8445178m/px, unfortunately there is no nice round number of 1 or 2 meter per pixel scales in ArcGIS.
Check out the source from [[http://www.arcgis.com/home/webmap/viewer.html?useExisting=1|ArcGIS.com]] using your browser only.
====== Selecting Square Area ======
[PTR] brenden0309: in terraincognita your right you can't enter a square selection but I make my map selection starting in this program by making a square and in bottom left you can see size in pixels and meters/kilometers and I resize by dragging outer edges to desired size and get it 100% square in size the double check the pixles because it won't always be the same and just move it a little more to make sure both values are square and then I download , I do that first because you can copy the four coordinates from that selection and collects max and mins to but in the opentopo website and then your selections are 100%accurate
[PTR] brenden0309: You can also save it as an arcview and will make tiles you can put together to have a solid png or jpg
[PTR] brenden0309: It's painstaking but works and a good tip when you download through opentopo you get a Google Maps kmz or something you can open in Google Earth and allows you to show where your map is helping with buildings and roads without guessing where your boundary is
[PTR] brenden0309: I can't remember if it puts a dark overlay on it or not but it definitely selects the area and then you can put any image as an over lay and change transparency
====== Example Workflow ======
This is how we here at PMC sekret codelabs use Terra Incognita (TI) with Global Mapper (GM).
- open GM project with user created features grid to see your terrain area, have world street maps visible
- start TI, select map source -> maps.google -> google street maps
- now you can align your TI rectangle to cover your GM user created feature grid
- select bottom right corner no grid -> global -> 10m, or what grid size works with your terrain size
- use selection -> rectangle selection, draw rectangle, give it few kilometers larger size than your terrain
- you can adjust rectangle edges (or corners) by carefully LMB mouse dragging them. (if you LMB dark area your rectangle is lost!)
- align the rectangle to fully cover your terrain area by LMB dragging inside the rectangle
- turn off selection -> rectangle selection, so you can LMB drag move the map view around (otherwise you delete your rectangle on LMB)
- when selection is ready use map source -> maps.google -> google satellite map
- use zoom levels -> 100m for 1m/px or whatever zoom level you reguire (you should not go much above 500m 8m/px, just no reason for it)
- file -> save map -> oziexplorer map, choose directory and file name, click save
- if TI says very large area selected! continue? just hit ok, we are friends with Large
All done. Then just use GM or QGIS to open the oziexplorer .MAP files, but that is another page and another tutorial...
====== Connection Lost ======
Very rarely (and I do mean //very//) you get error dialog of: Exception Download: Unable to read data from the transport connection: The connection was closed.
Which then offers retry and cancel options.
If you hit retry you'll get new dialog of some generic C# (I think) error of "System.IO.IOException: " + few other function exception errors. There is OK button and clicking that allows you to resume the download.
====== Downloading HUGE Satellites ======
For those monster sized terrains when you download satellite imagery larger than 50,000 x 50,000 pixel resolution it is very much recommended you split the downloads to four (or more) smaller areas.
On january 2019 I downloaded 409km x 409km sized chunk of mongolia arcgis 16 level and it took me **10 days!** yes, ten days of continuous download. This was because after the first couple of days the download speed of those cache-tiles slows down from the beginning several tiles per second to maybe even as slow as one tile in 3-4 seconds. This will drag the download time to incredibly long.
I already seen this back in 2017 when downloading 200+ satellites to PMC real world data terrains and now with the mentioned mongolia I've had enough. Now all our downloads above 40km x 40km terrains will be split to four smaller areas.
There are no slowdown on 40km area downloads that I can notice, so lets say you download 81km terrain then simply split terra incognita downloads to four. See below KMZ Rectangle for practical example.
====== KMZ Rectangle ======
**Howto get terrain area from global mapper into terra incognita.**
Global mapper export KMZ/KML file from your user created feature grid.
Terra incognita select file -> load waypoints, tracks, routes, then browse to your new KMZ file. Now black rectangle appears in the coordinates.
Example: for 81km 1m/px KMZ rectangles select arcgis zoom level 11 and make terra incognita fullscreen, now you have very clear view of the KMZ black rectangle (maybe you need to use openstreetmap source for brighter background depending on the terrain type). Now draw your normal rectangle selection over this black rectangle area.
If you are downloading in split to four smaller selections, then simply select rectangle of about 43km x 43km in size, place it on north west corner and copy coordinates to clipboard and save them. Then move rectangle to north east corner, copy coordinates to clipboard and save them... repeat this to south west/east corners as well. Now you have four sets of coordinates to 43km x 43km regions which are very quick to download.
Use waypoints,tracks -> visible to hide/disable the KMZ black waypoints rectangle. Start your download normally (black KMZ rectangle will NOT be saved to the satellite imagery).
====== Black Tiles ======
**2021-10-06**
Sometimes when you download satellite imagery using terra incognita there are very few black tiles in the oziexplorer images. I don't know why this happens... but you can fix it by simply re-saving the same oziexplorer image (set).
Oh that "sometimes" means that ... its ALMOST every terrain save you do (meaning one out of four corners). The amount of black tiles I got while doing PMC Taiwan terrains in oct 2021 was very high, so high that I had to do [[real-world-data-tutorial|real world data]] tool pipeline task to check saved corner JPGs with [[:editing_tools#image_editing|irFanview]] before even making global mapper map catalog.
This is why its important that after you finish DOWNLOADING satellite imagery you do not delete terra incognita CACHE directory / files until you have confirmed that all oziexplorer images are without black tiles.
Use irFanview or similar quick image viewer to check all the JPG images, if you find any black tiles then simply terra incognita re-save oziexplorer and check again until no more black tiles are present.