* * *

Translations for our friends around the world.

Click on banner for Tacview website

Save

Author Topic: Custom textures and orthophotos are coming soon!  (Read 691 times)

0 Members and 1 Guest are viewing this topic.

Offline Vyrtuoz

  • Moderator
  • *****
  • Posts: 87
  • Tacview Developer
    • Tacview The Universal Flight Analysis Tool
Custom textures and orthophotos are coming soon!
« on: July 27, 2017, 04:30:27 PM »
Up to now, when you wanted to use your own custom terrain textures in Tacview, you had to create perfect 1x1 degree tiles.

In Tacview 1.6.3, you can now freely declare as many custom textures as you want with non-square coordinates. Transparent textures are also supported so you can combine them to display advanced layers.

Even if the feature is not as powerful as it will be in the new terrain engine currently in development for Tacview 2.0, this should already be more than enough to easily display your own maps in Tacview 3D world.

Click.gif

Offline Asid

  • HAVOC
  • *
  • Posts: 11747
Re: Custom textures and orthophotos are coming soon!
« Reply #1 on: July 28, 2017, 12:46:22 AM »
This is a big help.

Great news  :thumbsup

I stand against Racism, Bigotry and Bullying

Offline pdmarsh

  • New member
  • *
  • Posts: 17
  • New member
Re: Custom textures and orthophotos are coming soon!
« Reply #2 on: August 11, 2017, 03:29:57 PM »
I have been experimenting with this great new feature and want to pass on a few things I have learned.

Two sources of orthoimagery and maps are The National Map (https://nationalmap.gov/) and EarthExplorer (https://earthexplorer.usgs.gov/).  The high resolution orthoimages on EarthExplorer appear to be of a higher resolution than those on The National Map.  Also, the latter has stated that they will no longer offer orthoimagery in the near future, but you can still get maps from that site.  Both sites offer methods for bulk download of images.

After spending way too much time manually stitching together orthoimage tiles, I finally found a program that does this for you.  It's a very powerful open source platform for working with geographical information.  It took some experimenting, but I finally found a way to automatically merge tiles and output a downsized jpg image file.  I'll provide the steps below.  The program is called QGIS (http://www.qgis.org/en/site/about/index.html).

There will be a trade-off between file size, i.e. quality, and load time for any given orthoimage to be used in TacView.  I haven't found the sweet spot yet, but my images of airports and some of the surrounding area are on the order of 10MB.  You do have to wait for them to load, but I tried lower res images and they start to get fuzzy when zoomed in.  Any guidance on this issue will be appreciated.

I suppose I shouldn't be surprised, but I am truly amazed at how will things line up.  My flight paths are right down the center lines of runways and taxi routes in the middle of taxiways.  I'll post some images below.

First, here are the steps to merge orthoimages in QGIS and output a jpg file.  Be advised that these files are huge.  It will take time for the process to complete.  Also, if the resulting jpg image is still too large a file, you might have to reduce its resolution further in another graphics package.  Either that, or choose a lower scale when you do the conversion (see below on that step).

1.  At this point it's assumed that your downloaded geotiff image tiles have been unzipped and are in the same folder.
2.  Open QGIS and click on "Raster/Miscellaneous/Merge..."



3.  In the dialog box that opens, select the files to be merged and set your output to a tif file.  I tried a direct conversion to jpg at this stage and it did not work.  Click "OK."  Now, go have a beer or two, go to a movie, spend time with your significant other; i.e. this takes time.



4.  After the merged tif file has been created, click on "Raster/Conversion/Translate (Convert Format)..."



5.  In the dialog box that opens, select the merged tif file and create the jpg output file and location.  Next, enable "Outsize" and set it to 20%.  This is the point where you can choose a higher or lower scale to suite your needs.  The resulting jpg file might still be rather large.  I have used a graphics program to downsize it further in some cases.



That's pretty much it for QGIS.

Now you will have to edit the "CustomTextureList.xml" file.  Getting the coordinates is fairly straight forward.  If you do this often enough, you will see a pattern to the image tile file names (numbers).  Depending on the source they might start in the lower left and go up, then start again just to the right and go up again.  The numbers increment.  Figure out which tiles make up the corners of the merged image and go to their associated xml files that came with the bulk download.  Their coordinates are buried in the xml files.  Now it's just a matter of choosing the correct lat and long coordinates for the given tile.  You might think that the lower left tile and lower right tile will have the same latitude, but there can be small differences.  However, in one image below I had to use the lat and long numbers from other corner tiles as there are missing tiles (water).  These missing spaces show up black in the final jpg image.

Here are some examples:

KILM Wilmington, NC (I bought the airport scenery package for X-Plane)



KATL Atlanta (My destination after departing from KILM)



KHRT and KVPS (Hurlburt Field, where my son was stationed, and KVPS (Eglin/Fort Walton Beach)



Thanks for adding this feature to TacView.

Paul




Offline Asid

  • HAVOC
  • *
  • Posts: 11747
Re: Custom textures and orthophotos are coming soon!
« Reply #3 on: August 11, 2017, 03:43:25 PM »
Great post pdmarsh

Thanks for taking the time to make it  :thumbsup

I stand against Racism, Bigotry and Bullying

Offline pdmarsh

  • New member
  • *
  • Posts: 17
  • New member
Re: Custom textures and orthophotos are coming soon!
« Reply #4 on: August 11, 2017, 03:54:34 PM »
Great post pdmarsh

Thanks for taking the time to make it  :thumbsup

My pleasure.  I started working with orthoimagery using World Editor (WED) for X-Plane when creating custom scenery.  This experience has helped me learn more about using and manipulating the files.

Paul
« Last Edit: August 13, 2017, 03:31:04 AM by pdmarsh »

Offline pdmarsh

  • New member
  • *
  • Posts: 17
  • New member
Re: Custom textures and orthophotos are coming soon!
« Reply #5 on: August 12, 2017, 06:45:54 PM »
What a difference a coordinate makes!  In the screenshot just below I was using a texture with missing tiles.  For the bottom right coordinates I had to use the latitude of the bottom left tile and longitude of the upper right tile.  Notice how the landing flight path angles off the runway and the taxi paths are off off the taxiways altogether.



In the screenshot below I used a texture with the bottom row and right column of tiles removed.  Now I used the real coordinates of the new bottom and upper right tiles.  The flight and taxi paths line up perfectly.  I was surprise how much of a difference it made having to use inferred coordinates for a single corner as I did in the first case.


Offline Vyrtuoz

  • Moderator
  • *****
  • Posts: 87
  • Tacview Developer
    • Tacview The Universal Flight Analysis Tool
Re: Custom textures and orthophotos are coming soon!
« Reply #6 on: August 21, 2017, 04:37:20 PM »
Very nice work Paul!

There is currently no limitation on the images size. However, the bigger they are, the longer it will take to load them.

Tacview uses up to 25% of available physical RAM for up to a total of 2 GB of cache to store your UNPACKED pictures in memory. So, as long as your pictures fits in it the cache, the performances should be ok. If the cache overflows, the loading will just take more time.

For reference:
Code: [Select]
Unpacked size of one jpeg picture in bytes = width_in_pixels * height_in_pixels * 5

Also, for general performances reason, the maximum resolution of a picture is roughly equivalent to an orthophoto of ZL14 (I think, I did not do the math for real). Higher resolution level will not be visible with the current terrain engine of Tacview.

Tacview 2.0 terrain engine should be able to display any ZL resolution and the maximum size of a picture will be restricted by your graphic card (could be for example 8192x8192 pixels max per image). The “loading” should also be much faster.
Click.gif

Offline I-VM10

  • New member
  • *
  • Posts: 2
  • New member
Re: Custom textures and orthophotos are coming soon!
« Reply #7 on: December 03, 2017, 06:57:17 PM »
Hi,

I tried to add a picture with transparent part of it, just to display only the airport on another set of maps from SkyVector.
Maps from SkyVector are correctly loaded.
the format of the partially transparent file is PNG but this does not work: tacview does not load the picture.
Is there another format which could be used or it is a matter of properties of the file?
Thanks for your support
Kind regards
Roberto



Offline Vyrtuoz

  • Moderator
  • *****
  • Posts: 87
  • Tacview Developer
    • Tacview The Universal Flight Analysis Tool
Re: Custom textures and orthophotos are coming soon!
« Reply #8 on: December 04, 2017, 05:26:04 PM »
Hello Roberto,

PNG files should work fine. As a matter of fact, they are the only transparent files supported by Tacview.

Can you share me the set of data you are using? I will do some tests and check what is going on. Maybe there is a mistake in the XML file declaration, maybe I have made a mistake in the layering process…
Click.gif

Offline I-VM10

  • New member
  • *
  • Posts: 2
  • New member
Re: Custom textures and orthophotos are coming soon!
« Reply #9 on: December 08, 2017, 08:14:12 PM »
Hallo Vyrtuoz.
Sorry for the late reply.
Maybe I did something wrong with the image's properties notwithstanding it was a png file.
Now it is all ok.
Thanks for your help.
Kind regards
Roberto

 

Official Tacview news feed