Skybolt
Skybolt copied to clipboard
Most of the time, the terrain does not show and it fails silently
Hi Matthew,
I've recompiled with the latest version of the master branch (thanks for that). I've been able to see the terrain load properly several times, but most of the time, it does not even show, without errors or warning. It seems thought that the cache is being populated.
Independent from the fact that the terrain does not show, here are some of the errors/warnings I get.
[2022-06-11 06:53:55.435785] [0x000051f4] [error] Error reading file Tiles/Earth/Attributes/0/0/0.png: file not found
[2022-06-11 06:53:55.440790] [0x000051f4] [error] Could not load image from XyzTileSource with URL template 'Tiles/Earth/Attributes/{z}/{x}/{y}.png.
Those errors indicate that the NLCDLandCover tiles are missing. That should not be the cause of the terrain now showing however, as the NLCD tiles are only used for tree placement. The terrain should still show without the NLCD tiles.
Are there any other errors?
Do you see some tiles present and other tiles missing in the same run of the application? If so can you please post a screenshot of the terrain getting partially shown?
Is the cache being populated with valid textures (either colored albedo textures or grey heightmaps)?
Concerning the NLCDLandCover, I've added the proper path to SKYBOLT_ASSETS_PATH
the environment variable. Errors mentioned above no longer show.
Now, there are absolutely no errors.
[2022-06-11 07:44:14.155660] [0x000006fc] [info] No --settingsFile program argument specified. Using default settings file location: '"C:\\Users\\xxxxx\\AppData\\Local\\Skybolt\\Settings.json"'
[2022-06-11 07:44:14.155660] [0x000006fc] [info] Reading settings file '"C:\\Users\\xxxxx\\AppData\\Local\\Skybolt\\Settings.json"'
[2022-06-11 07:44:14.155660] [0x000006fc] [info] 12 CPU cores detected. Creating 11 background threads.
[2022-06-11 07:44:14.155660] [0x000006fc] [info] Registered asset package: Core
[2022-06-11 07:44:14.155660] [0x000006fc] [info] Registered asset package: Globe
[2022-06-11 07:44:14.155660] [0x000006fc] [info] Registered asset package: Movers
[2022-06-11 07:44:14.155660] [0x000006fc] [info] Registered asset package: NLCDLandCover
Concerning:
Do you see some tiles present and other tiles missing in the same run of the application? If so can you please post a screenshot of the terrain getting partially shown?
No, when the terrain shows up, everything looks fine (as far as I can tell).
Is the cache being populated with valid textures (either colored albedo textures or grey heightmaps)?
Yes it is, even when the terrain does not show. But in such case, only the one tile at the planet scale is present. If I zoom in, smaller scale tiles are not downloaded. Btw, I made sure to delete the cache every time I reloaded MinimalApp.exe
.
Since it's intermittent, one possibility is a multi-threading related bug. I do my testing on a 4 core PC. Perhaps your 12 cores is exposing a bug. Try setting the environment variable SKYBOLT_MAX_CORES=4 or SKYBOLT_MAX_CORES=1 and see if you get more consistent results.
Hi Matthew,
Still occurs with SKYBOLT_MAX_CORES
set to 1.
SKYBOLT_MAX_CORES
is really being taken into account:
[2022-06-12 08:28:23.169058] [0x00002cb0] [info] 1 CPU cores detected. Usable cores limited to environment variable SKYBOLT_MAX_CORES=1. Creating 1 background threads.
Since the cache is populated, it seems like the tiles are loading but failing to display. I'd difficult for me to debug the issue without being able to reproduce it. I'd suggest putting breakpoints in the code to determine where it might be going wrong.
PlanetTileImagesLoader::load()
in Skybolt/SkyboltVis/Renderable/Planet/Tile/PlanetTileImageLoader.cpp
is where all the tile images are loaded. See if that function returns a valid result.
If it makes it that far, the next thing to check is OsgTileFactory::createOsgTile()
in Skybolt/SkyboltVis/Renderable/Planet/Tile/OsgTileFactory.cpp
where OSG geometry is created from the tile images.
Another thing you could check is whether any other geometry is displayed. For example, do you see the helicopter, buildings and trees in the FlightSimApp
?
Another thing you could check is whether any other geometry is displayed. For example, do you see the helicopter, buildings and trees in the FlightSimApp?
Yes, I do see the helicopter (thanks for removing Bullet's dependency btw).
I will try to find the problem myself, but that may not be for tomorrow :)
Is there a windows platform tutorial for this compilation. Help me please. thanks!!!!!
@IMHinnG There's no windows tutorial unfortunately. You can either build skybolt with conan, or more directly with CMake.
If you're taking the conan route, there's an example github workflow here which you can use as an example: https://github.com/Piraxus/Skybolt/blob/master/.github/workflows/main.yml
If you're using CMake directly without conan, you need to download and place the dependencies (listed in the Skybolt README.md) and put there somewhere CMake can find them (e.g CMAKE_MODULE_PATH), then Run CMake configure and generate steps, then open the solution in visuals studio and build.
If you have any more questions about the build process please create a new issue as this one's for the terrain bug.
I'm having a terrain problem as well.
Error reading file http://api.mapbox.com/v4/mapbox.terrain-rgb/0/0/0.pngraw?access_token=pk.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx: file not handled
However, when I open this url in the browser, it shows an image. It isn't handling it for some reason.