Modified Track Path Editor + Tracks/Discussion

Also your editor works on all themes, not just Andalusia.
@tarnheld I'm currently working on an Eifel track with your editor and it works nicely, though obviously there's a lot of guesswork to find a good place for it with the andalusia background map :lol:
Seems this "feature" is more of a mishap, actually i don't change the scenery of an imported file, so if it's Eifel it stays Eifel (with heights coming from the Andalusia heightmap...), just the contours are wrong, but they are more of a visual help. I'll try to add some heightmap/contour changing commands Soon™.
 
Update time! Elevation editor 1.1.0 :gtpflag:

Changes from previous version:
  • Corrected the way the x coordinate is calculated for the height data. I discovered that it previously used the track distance including height. Now it correctly uses track distance excluding height. This also means that the slope graph now displays the correct slope steepness and that the accuracy of the height editing tools is improved.

  • The positions of all track objects are dynamically recalculated to reflect the changes done to the elevation. Since the track distance increases when the elevation changes are increased and vice versa, all the objects used to move around a little when the elevation was changed. In some instances (such as when flattening a track with big elevation changes) it also caused the positions of some objects to go beyond the actual track length, causing the game to crash when trying to import that track. Based on the tests that I've done, that should no longer be an issue.

  • The editor now recognise if a track is a loop course or a point to point course. When it's point to point it will no longer edit the start of a track when the brush exceeds the end, or vice versa.

  • The header data of the TED file is now being updated to reflect the changes you've made to the track. Most importantly, the elevation change listed in the game will now be correct.

  • The editor now remembers the name of the file when it was loaded, and will default to using the same name when you export it. The name can of course still be changed in the save dialog.

  • Lots of behind-the-scenes updates that will enable an expansion of the editor's functionality in future updates. For instance, the readfile.py script has been completely replaced by a new script (the new script is called readfile_2.py, since it's not backwards compatible with earlier versions of the elevation editor).

Since some of these are quite big changes concerning the internal framework of the editor there is a chance that there are some bugs hiding in the code. If you find any, please let me know!

Edit: Fixed a bug where the dialogs used for loading and exporting files could not be found.

Edit 2: Fixed an issue where files from @tarnheld's TED editor would not load properly.
 

Attachments

  • elevation editor 1.1.0.zip
    14.4 KB · Views: 30
Last edited:
Update time! Elevation editor 1.1.0 :gtpflag:

Changes from previous version:
  • Corrected the way the x coordinate is calculated for the height data. I discovered that it previously used the track distance including height. Now it correctly uses track distance excluding height. This also means that the slope graph now displays the correct slope steepness and that the accuracy of the height editing tools is improved.

  • The positions of all track objects are dynamically recalculated to reflect the changes done to the elevation. Since the track distance increases when the elevation changes are increased and vice versa, all the objects used to move around a little when the elevation was changed. In some instances (such as when flattening a track with big elevation changes) it also caused the positions of some objects to go beyond the actual track length, causing the game to crash when trying to import that track. Based on the tests that I've done, that should no longer be an issue.

  • The editor now recognise if a track is a loop course or a point to point course. When it's point to point it will no longer edit the start of a track when the brush exceeds the end, or vice versa.

  • The header data of the TED file is now being updated to reflect the changes you've made to the track. Most importantly, the elevation change listed in the game will now be correct.

  • The editor now remembers the name of the file when it was loaded, and will default to using the same name when you export it. The name can of course still be changed in the save dialog.

  • Lots of behind-the-scenes updates that will enable an expansion of the editor's functionality in future updates. For instance, the readfile.py script has been completely replaced by a new script (the new script is called readfile_2.py, since it's not backwards compatible with earlier versions of the elevation editor).

Since some of these are quite big changes concerning the internal framework of the editor there is a chance that there are some bugs hiding in the code. If you find any, please let me know!

Has this version been incorporated into tarnheld's editor yet ?
 
I don't think so, but it's probably just a matter of time :)

When I tried opening a file with your new editor straight out of the box I got an error and no dialog popped up.

Code:
Exception in Tkinter callback
Traceback (most recent call last):
  File "C:\Users\Personal\AppData\Local\Programs\Python\Python35-32\lib\tkinter\__init__.py", line 1550, in __call__
    return self.func(*args)
  File "D:\Downloads\elevation editor 1.1.0\elevation editor 1.1.0.py", line 422, in _load_ted
    structure = rf.load_TED()
  File "D:\Downloads\elevation editor 1.1.0\readfile_2.py", line 333, in load_TED
    path = tk.filedialog.askopenfilename(**file_opt)
AttributeError: module 'tkinter' has no attribute 'filedialog'
 
When I tried opening a file with your new editor straight out of the box I got an error and no dialog popped up.

Code:
Exception in Tkinter callback
Traceback (most recent call last):
  File "C:\Users\Personal\AppData\Local\Programs\Python\Python35-32\lib\tkinter\__init__.py", line 1550, in __call__
    return self.func(*args)
  File "D:\Downloads\elevation editor 1.1.0\elevation editor 1.1.0.py", line 422, in _load_ted
    structure = rf.load_TED()
  File "D:\Downloads\elevation editor 1.1.0\readfile_2.py", line 333, in load_TED
    path = tk.filedialog.askopenfilename(**file_opt)
AttributeError: module 'tkinter' has no attribute 'filedialog'

Fixed, I hope...

Replace the readfile_2.py script with the script attached here and it should work. I have also updated the zip file in the original post.
 

Attachments

  • readfile_2.zip
    3.6 KB · Views: 12
Can anyone make the "Eboladrome Test Track" from The Grand Tour? Its got interesting layout.

While the parts of the track that are used twice can't be replicated they could be side by side. It'd change the angle of entry to your name here corner and maybe lengthen the straight before the final corner a bit. Still would be pretty fun in all actuality.

Edit:

https://www.formula1.com/en/latest/...f1-track-has-the-most-elevation-changes-.html

Add that to the resource list. Happy creating friends.
 
Last edited:
Elevation editor 1.1.1

Changes:
  • New transformation tool: Resample. This tool lets you change the resolution of the elevation data, by setting a maximum distance between height points. The editor renders a new set of height data based on this maximum distance and samples the old height data to determine the new heights.

    Currently there are no preset limits (will be added in a future version) so be careful about setting the maximum distance too low or too high. For example, a 10'000 meter track resampled with a maximum distance of 1 meter will create more than 10'000 height data points and there is a risk that the editor and/or the game will have difficulties dealing with so much height data. And at the other end of the spectrum, I'm not sure how the editor will respond if you set the maximum distance to be longer than the length of the shortest bank. As a rough guideline I believe the default resolution created by the TPE app ranges from about 3 to 10 meters and the average probably lies somewhere around 6-7 meters.

    The resampling is applied to the entire track, but in the future it might be possible to set individual resolutions for each bank.

    Edit: Forgot to mention that Resample resets the undo history, so when you have resampled the track you can't undo any actions you did before that.
 

Attachments

  • elevation editor 1.1.1.zip
    15.2 KB · Views: 19
Last edited:
Last edited:
Watch this


Drive this
https://www.gtplanet.net/forum/resources/ahvenisto-circuit-rm-edition.5479/

And if you fancy a beer, you can pop round @Razerman's because I'm sure he don't live to far away :cheers:

Really pleased with this track, a personal favourite. Short yet very challenging.

Play around with the time/weather settings on this 1, look's fantastic :)

Also online room open.

Love the brake pedal!! PD should update the SFX to have cars make the odd squeak/rattle as they wear down:D
 
Elevation editor 1.1.2

112.png

Changes:
  • Added individual feather settings for left and right feather. The controls are in the Brush Data panel to the left.
  • Feather settings and transformation commands have been removed from the edit menu, since they're now available in the panel to the left.
  • The keybind for 'redo' has been changed to ctrl+y.
  • Slopes are now redrawn at the end of a brush action, instead of during the brush action. This is because the redrawing function iterates over all of the height data tokens and when you have several thousands of data points (which you can, thanks to the resample function added in 1.1.1) it can be hard to maintain an acceptable framerate if the slopes are redrawn on every loop while you use the brush. So now you won't see the slopes update until after you have released to mousebutton.
The hardest part of this entire project so far was to figure out how to validate the spinbox widgets containing the brush and feather radii in the Brush Data panel. Never thought that such a small detail would be so hard to do...:banghead:

Edit: Made this slope graph comparison. Top graph is an unmodded track straight from the TPE app. Bottom graph is the same position in the modded version of the same track. The slopes and the track surface are a bit more dynamic in the modded version :)

before.png

after.png
 

Attachments

  • elevation editor 1.1.2.zip
    15.7 KB · Views: 32
Last edited:

Just got around to trying this. Excellent work as usual 👍 The elevation changes are not as apparent as the original in GRID, but I suspect it's due to the limitations of the modified editor. Still a very enjoyable track in its own right though.

Also tried the RRV RM, which is absolutely perfect and spot on in terms of recreating the feel of the original track 👍

If I could make a suggestion maybe try Grindelwald from GT2 next? On Eifel and make sure you plant lots of trees on the sides :D
 
Just got around to trying this. Excellent work as usual 👍 The elevation changes are not as apparent as the original in GRID, but I suspect it's due to the limitations of the modified editor.

It's probably due to the lack of good reference data.

...which gives me an idea for a future update ;)
 
It's probably due to the lack of good reference data.

...which gives me an idea for a future update ;)

Yes, that too. In any case, it's a pretty fine replica given the tools we have to work with. Maybe he could make the point to point version that is in GRID 2 as well? 50% of the track is shared with the Okutama GP circuit so it will cut down the workload considerably.

 
Oran Park Raceway next. Then I'll tweak Monza & add a tunnel under the banked curve on so you don't have to drive through scenery. Followed by re-modding Highlands Motorsports Park.

Regarding Okutama, without no elevation data available all I could do was do it by feel (play Grid AS then play GT6) so I think I didn't do too bad :)
 
Last edited:
Back