Board index FlightGear Development Scenery

No more seams in FG Terrain Tiles with GLUE tool

Questions and discussion about enhancing and populating the FlightGear world.

No more seams in FG Terrain Tiles with GLUE tool

Postby maxkant1 » Thu Jul 04, 2019 7:05 pm

Hi all,
I have developed a small tool named GLUE to solve Flightgear Scenery and terrain developers well known problem of “seams” that can arise, for a lot of reasons, when trying to upgrade and substitute old terrain tiles with newer ones. In general tiles boundaries do not match and different heigths of triangles show cracks in the terrain.

Please have a look to the images referred to LIEO apt tile (3104954 E09N40) before and after the application of GLUE tool:

Before GLUE
Image

After GLUE
Image

Before
Image

After
Image

More images at the following address:
https://github.com/maxkant1/FG-TILEGLUE/tree/master/IMAGES

GLUE started initially with few main goals: understand BTG file structure, test algorithms and demonstrate feasibility, but it has developed quickly and has produced first results.

You will find the source code (VB.NET, please do not blame me, I'm sure that C programmers clever than me could port easily the code to C), a quick manual, executable code of GLUE, some byproducts utility into GITHUB repository at the following address:

https://github.com/maxkant1/FG-TILEGLUE

At this stage the program is working but it needs deeper testing and some code optimization.
So please, feel free to try and experiment and please give me your feedback, or contact me in the FG Forum and send me your terrain tile, I'll try to fix it for you.

Have fun

maxkant1
maxkant1
 
Posts: 15
Joined: Sun Nov 27, 2016 2:54 pm

Re: No more seams in FG Terrain Tiles with GLUE tool

Postby wlbragg » Thu Jul 04, 2019 7:10 pm

What is "GLUE" doing exactly? Is it simply texturing the seems with a more or less neutral color or texture?
Kansas(2-27-15)/Ohio/Midwest scenery development.
KEQA (2-27-15), 3AU, KRCP Airport Layout
Intel i5 3570K AMDRX480
User avatar
wlbragg
 
Posts: 4989
Joined: Sat Aug 25, 2012 11:31 pm
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/AMDRX480

Re: No more seams in FG Terrain Tiles with GLUE tool

Postby legoboyvdlp » Thu Jul 04, 2019 8:57 pm

Not quite sure, but it looks like it actually edits the BTG file to remove the seams. Whatever it is, it looks great and will help with scenery development. :) Thank you very much!
User avatar
legoboyvdlp
 
Posts: 7184
Joined: Sat Jul 26, 2014 1:28 am
Callsign: YV-LEGO
Version: next
OS: Windows 10 HP

Re: No more seams in FG Terrain Tiles with GLUE tool

Postby maxkant1 » Thu Jul 04, 2019 10:21 pm

Exactly Legoboyvdlp, GLUE automatically edits btg files, modifying heights of triangle vertex and adding triangle vertex, if necessary, along the boundary profile, in order to connect correctly triangles of first tile and triangle of the border tile. Moreover, working with triangles, GLUE mantains the FG class. I mean, if the original triangle is Drypasturecover, the generated triangles will be the same class. And, all other parameters, like normals components, (colors if any) and texture vertex components are linearly interpolated along the side of the triangle that is on boundary.
So wlbragg, GLUE work is more complicated than texturing with a more or less neutral color :)
Tank you both for your request and kind comment

Maxkant1
maxkant1
 
Posts: 15
Joined: Sun Nov 27, 2016 2:54 pm

Re: No more seams in FG Terrain Tiles with GLUE tool

Postby pb321 » Fri Jul 05, 2019 3:50 am

This looks like a significant tool! I'm looking forward to trying it out. Thank you!
pb321
 
Posts: 140
Joined: Sun Nov 27, 2016 4:08 pm
Version: 2019.2.1
OS: Windows 10 Pro

Re: No more seams in FG Terrain Tiles with GLUE tool

Postby maxkant1 » Fri Jul 05, 2019 5:57 am

Thank you pb321. Yes please try it and let me know for problems. The program needs test and optimization.
maxkant1
 
Posts: 15
Joined: Sun Nov 27, 2016 2:54 pm

Re: No more seams in FG Terrain Tiles with GLUE tool

Postby maxkant1 » Sun Jul 07, 2019 9:32 pm

I'd like to add that the deep insight into BTG file structure that was a significant part of the developing efforts of GLUE, could open some interesting fields to explore, among the most interesting:

- Reverse engineering of tiles to data (yes I mean to get 3d model of terrain and shape file of terrain classes used to setup a tile by Terragear toolchain)
- remove gaps from tile bucket and airport btg file (yes sometimes gaps happens also in apt boundary)
- output the btg file structure in different coordinates systems in well known open 3d data format (what about obj ascii format?). I know of the great btg to blender exporter, but it could be another useful tool, considering that obj ascii format and btg have in some sense a similar structure.

Let me know what do you think about.

maxkant1
maxkant1
 
Posts: 15
Joined: Sun Nov 27, 2016 2:54 pm


Return to Scenery

Who is online

Users browsing this forum: No registered users and 2 guests