Height Maps from the APK

  • Thread starter Outspacer
  • 217 comments
  • 35,467 views
The height is important, but you can get a sense of that from the lines. I like to see the background shading for landmarking purposes, when measuring distances between corners, how long a straight should be, etc. Doing it with gridlines is too slow for me lol. By using landmarks is a lot more intuitive 👍 That's the whole reason why I'd like to overlay the 2 things together in the first place.

Of course if PD allows us to use reference image for the 3 non-flat areas we wouldn't need to do this :banghead:

I think those are perfect for my use now. Andalucia could use more contour lines, but I can just refer to eran's maps for that. Thank you so much mate 👍:cheers:

After writing that reply to Venari, I did wonder if removing the home straights from the scenery files in the APK would also allow the reference image to work. That would be a nice bonus, but I've no idea if it would!

My previous method of writing contours to an .svg file, then converting to .png, blew up trying to do more contours for DV - Java out of memory, over 2 gig, lol. So now I just go direct to .png, only use 75MB, and get smoother lines as well :)

Eifel_800_pastel_2.png


Andalusia_800_pastel_2.png


Death_Valley_800_pastel_2.png


Eifel_Flat_800_pastel_2.png
 
After writing that reply to Venari, I did wonder if removing the home straights from the scenery files in the APK would also allow the reference image to work. That would be a nice bonus, but I've no idea if it would!

My previous method of writing contours to an .svg file, then converting to .png, blew up trying to do more contours for DV - Java out of memory, over 2 gig, lol. So now I just go direct to .png, only use 75MB, and get smoother lines as well :)

That is even more perfect :drool: You are the man Outspacer :bowdown:

Also to mods, may I suggest this thread to be stickied?
 
After writing that reply to Venari, I did wonder if removing the home straights from the scenery files in the APK would also allow the reference image to work. That would be a nice bonus, but I've no idea if it would!

I'm thinking that somewhere in the code there should be a simple switch to toggle a background reference image on/off. It would surprise me if Eifel Flat is using a completely different code than the other sceneries.

But I also saw the third party website where you can edit your course maker tracks (don't remember the URL right now, but I think it was made by someone from GTPlanet). There shouldn't be such a big leap from doing that to creating a fully functional community created track path editor that you can use to make tracks from scratch. And perhaps it would be easier to have the contour maps displayed there, rather than inside the PD-created app?
 
That is even more perfect :drool: You are the man Outspacer :bowdown:

Also to mods, may I suggest this thread to be stickied?

Thanks! :D There's still more to do, but it will have to wait for a week or two. Then I'll try boosting the lighting, go to high res, etc, and post images along with all layers separately.
 
I'm thinking that somewhere in the code there should be a simple switch to toggle a background reference image on/off. It would surprise me if Eifel Flat is using a completely different code than the other sceneries.

Indeed, everything else appears to be data driven. So that switch could be "home_straights_count == 0".

But I also saw the third party website where you can edit your course maker tracks (don't remember the URL right now, but I think it was made by someone from GTPlanet).

That's the excellent work of @PR1VATEJ0KER :)

There shouldn't be such a big leap from doing that to creating a fully functional community created track path editor that you can use to make tracks from scratch. And perhaps it would be easier to have the contour maps displayed there, rather than inside the PD-created app?

Yes, that would be much better, and is what I'm gearing these images towards. Modifying the scenery files in the .apk isn't connected to this, but if possible, might allow moving the boundaries outwards, placing home straights anywhere, and reference image on maps other than Eifel Flat. I wasn't thinking of enabling the reference image to show the contour map, although I suppose it could (alignment being a big issue). It would be pretty quick to try, and I think it's worth investigating anyway in case PD add some extra validation of tracks into the app - tracks from an alternative editor still have to pass through it.
 
A TPE with contour map backgrounds would be much more useful. One with expanded borders for a bit of mountain action would be great. One with adjustable start points in any map would be awesome.
 
@Outspacer after you extract the height map txt , what do you use to view it ?
Do you need to do anything to the txt file ?

EDIT : I see the format from earlier posts now.
 
Last edited:
💡 No, but for a little work around you could use Photoshop (or your preferred image editor) to overlay a semi-transparent track layout onto an image of one of the other themes, then use that as the reference in Eiffel_Flat and then change the theme number in PJ's editor.... that way you will know where the track is gonna be when you open it in the new theme.

Unlike my 4.56x bigger TG Track.......
 
💡 No, but for a little work around you could use Photoshop (or your preferred image editor) to overlay a semi-transparent track layout onto an image of one of the other themes, then use that as the reference in Eiffel_Flat and then change the theme number in PJ's editor.

Yes, but you still need a rooted Blustack/tablet for that, right? I can't be bothered with all the faff of that. It's what I want to achieve but I'm not willing to goof up all my current tracks or the Bluestacks install to be able to do it.
 
💡 No, but for a little work around you could use Photoshop (or your preferred image editor) to overlay a semi-transparent track layout onto an image of one of the other themes, then use that as the reference in Eiffel_Flat and then change the theme number in PJ's editor.... that way you will know where the track is gonna be when you open it in the new theme.

Unlike my 4.56x bigger TG Track.......

Nevermind, I was kind of hoping there was a "use reference image true or false option" in the core .apk that PJ could work his magic on like the max length or no boundaries & such.
 
@Outspacer after you extract the height map txt , what do you use to view it ?
Do you need to do anything to the txt file ?

EDIT : I see the format from earlier posts now.

Was AFK... have you got it sorted now? I wrote some C code to read/convert it - scruffy code that I recompile to do the different things (linear .raw output in 8-bit or 16-bit, hue map, contours, lighting) . I just used the simple one-liner conversion on page 2 of this PDF to go from half to single precision, since there don't appear to be any zeros or infinities. Contours are done using Paul Bourke's 'conrec' routine.

So, what's the trick for removing the limits? :D And have you tried the scenery hacks I was talking about? - mainly I'm curious about what happens when the home straight definitions are removed.
 
Was AFK... have you got it sorted now? I wrote some C code to read/convert it - scruffy code that I recompile to do the different things (linear .raw output in 8-bit or 16-bit, hue map, contours, lighting) . I just used the simple one-liner conversion on page 2 of this PDF to go from half to single precision, since there don't appear to be any zeros or infinities. Contours are done using Paul Bourke's 'conrec' routine.

Cheers :cheers:

So, what's the trick for removing the limits? :D And have you tried the scenery hacks I was talking about? - mainly I'm curious about what happens when the home straight definitions are removed.

I'm pretty sure my post will be deleted if I'm talking about modding or hacking.
I'll send a PM and leave a note on my website for anyone interested.
 
Can confirm... height maps are used by the app to create the elevations of the course that ends up in-game.
The red bull was capable of scaling this near vertical slope, flew through the air & fell all the way down the other side. Elevation difference for the track was 800m in-game.

xOhzG5Q.png


Shared : https://www.gran-turismo.com/ie/gt6/user/#!/friend/PR1VATEJ0KER/course/

Created from this Heightmap, the anchors had to land on the high regions to send the track up there.
ntY9sdi.png
 
Last edited:
@PR1VATEJ0KER Turns out that quite a bit of cars can get up the incline as long as they have enough speed. At points where you would think that the car should fall over backwards, it remains glued to the road. PD just never worked on the physics for a vertical angle. (Why would they have though? I'm sure nobody expected to drive straight up!) Congratulations on breaking the physics engine.

On another note, it seems like you're developing your own elevation map. Would it be possible to create maps with proper elevation for circuit replicas? If so, with topography maps of race track areas and with "eifel on eifel flat" to allow traces with elevation, we could have near perfect real world track replicas in nearly every aspect.
 
@PR1VATEJ0KER Turns out that quite a bit of cars can get up the incline as long as they have enough speed. At points where you would think that the car should fall over backwards, it remains glued to the road. PD just never worked on the physics for a vertical angle. (Why would they have though? I'm sure nobody expected to drive straight up!) Congratulations on breaking the physics engine.

On another note, it seems like you're developing your own elevation map. Would it be possible to create maps with proper elevation for circuit replicas? If so, with topography maps of race track areas and with "eifel on eifel flat" to allow traces with elevation, we could have near perfect real world track replicas in nearly every aspect.

Sounds about correct to me.
If you use Eifel Flat, and can load a custom Height Map, based on the Circuit you want to re-create.
you can then import the GPX trace of the course.
you just have to place your nodes a the the elevation points.
That seems to be the key to getting good elevation changes.
a node right on the proper location.

Where version 1.0 fits a spline or Biarc from one elevation to the other,
1.0.2 has smoothed this to a gradual slope.

Wish I had the time to experiment more.
But that's the age old issue, Not enough time to do everything you want to do.

too bad the APK couldn't be modded to use the bin file with added Z data for the Height instead of the Height Map.
then you could create the Bin file externally.
and just use the APK to transfer it to GT6

externally you create
Track width, Banking angle, Node Points with Height.

here's another idea..

make a Mesh
say 64 x 64 points.
then each mesh point can be given a Height.
that way you can make a custom height map, just by pushing and pulling at the mesh points.
select multiple mesh points and alter them by the same relative amount.

then create a surface from the Mesh points.

Use that surface to create the new Height map.

then each track node would follow the contour of the custom created surface.
 
Can confirm... height maps are used by the app to create the elevations of the course that ends up in-game.
The red bull was capable of scaling this near vertical slope, flew through the air & fell all the way down the other side. Elevation difference for the track was 800m in-game.

xOhzG5Q.png


Shared : https://www.gran-turismo.com/ie/gt6/user/#!/friend/PR1VATEJ0KER/course/

Created from this Heightmap, the anchors had to land on the high regions to send the track up there.
ntY9sdi.png

How about 1 going down to the depths of hell :)

This was great fun with the AI :)
 
Last edited:
@Peelster1

Did this some weeks ago and I guess I got pretty good elevation replicated.
Circuit of the Americas

Might not be exact but I was happy with the results.

Impressive. When I was taking a look at your profile, I also saw that you recreated the seasonal event race tracks. Why PD doesn't give a download link in the seasonal event section of the game is beyond me. Your recreations look quite good. What was your method?
 
It bugs me that the land shown on the Andalusia theme doesn't seem to match the heights shown in the maps above and in the game. I made a track expecting it to cut between and along steep hills I see on the app, but when I load the track they're nowhere to be seen.
 
It bugs me that the land shown on the Andalusia theme doesn't seem to match the heights shown in the maps above and in the game. I made a track expecting it to cut between and along steep hills I see on the app, but when I load the track they're nowhere to be seen.

Some hills are just props, much like the towns you see at different places. They're there as background scenery only, and if you place the track too close to them they disappear.
 
Some hills are just props, much like the towns you see at different places. They're there as background scenery only, and if you place the track too close to them they disappear.
That makes sense. Thanks for the clarification.
 
Some hills are just props, much like the towns you see at different places. They're there as background scenery only, and if you place the track too close to them they disappear.

I noticed this too. There's a small hill with a building perched on top on the right side after the start/finish straight #7. When I moved my track to go around it the whole hill disappears. I moved my track to just pass beside it and it reappeared.

One time I got lucky with the rocks on the south part of the map and made a track that cuts right through it (so you have cliffs on either side), but I haven't been able to replicate it since. Very annoying.
 
Back