World Scenery 3.0 roadmap: Difference between revisions

From FlightGear wiki
Jump to navigation Jump to search
No edit summary
(Removed abandoned approach from news section)
 
(28 intermediate revisions by 5 users not shown)
Line 1: Line 1:
{{stub}}
{{Scenery Core Development}}
{{Scenery Core Development}}
{{WS30 Navbar}}
{{See also|TerraGear roadmap}}
{{See also|TerraGear roadmap}}
{{Project
{{Project
Line 33: Line 33:


[[File:Edinburgh rendering using WS3.0.jpg|thumb|Initial rendering of Edinburgh scenery using a raster landclass and texture lookup for city, water and grass]]
[[File:Edinburgh rendering using WS3.0.jpg|thumb|Initial rendering of Edinburgh scenery using a raster landclass and texture lookup for city, water and grass]]
 
[[File:WS3.0 terrain with WS2.0 EGPH.jpg|thumb|Screenshot showing a WS2.0 airport .btg file rendered with WS3.0 terrain]]
 
[[File:EGPH roads.jpg|thumb|WS3.0 Edinburgh airport with runtime-generated roads from OSM data]]
[[File:WS30 - West Lothian.png|thumb|WS30 view of West Lothian, with 25m resolution landclass data, vegetation, osm2city buildings, and OSM-based roads and rivers.]]
[[File:WS30 street lighting.jpg|thumb|Edinburgh at night, with osm2city buildings, OSM-base roads, including whether they are lit or not.  Note the road in the foreground which is lit near the buildings and unlit in the countryside.]]
[[File:Fgfs-20220528191253.png|thumb|WS30 using OSM data to define the coastline.  This shows a view near Oban in Scotland looking South.  The coastline is applied as a high resolution overlay texture that is generated at runtime from OSM data and mixed with the landclass texture by the ws30 shader.]]


Produce high-quality scenery using the best-known practices.
Produce high-quality scenery using the best-known practices.
Line 40: Line 43:
TerraGear becomes obsolete in favor of VPB.
TerraGear becomes obsolete in favor of VPB.


OpenGL 3.3 Core Profile: WS3.0 will require us to eliminate the usage of the fixed-function pipeline.<br/>
* '''OpenGL 3.3 Core Profile''': WS3.0 will require us to eliminate the usage of the fixed-function pipeline.<br/>
Shader-based Rendering: All of the terrain renderings will be done via GLSL shaders.<br/>
* '''Shader-based Rendering''': All of the terrain renderings will be done via GLSL shaders.<br/>
OSG Core: OpenSceneGraph will require targeting of the OpenGL Core Profile.
* '''OSG Core''': OpenSceneGraph will require targeting of the OpenGL Core Profile.


WS3.0 will continue to cooperate with osm2city.
WS3.0 will continue to cooperate with osm2city.


Easy upgrade: Airport layouts will be generated in real-time. Apt.dat will continue to be the primary source for airport layouts.
Easy upgrade: Initially the plan was that airport layouts will be generated in real-time. Apt.dat will continue to be the primary source for airport layouts and that airports will be draped over the terrain. This would eliminate the need to cut airport layouts into the underlying terrain.
Airports will be draped over the terrain. This eliminates the need to cut airport layouts into the underlying terrain.
Due to difficulties with this approach, it has been decided, that we keep using the WS2.0 airports for now. Work has been done to automatically update the airports from the X-Plane gateway which can be done automatically now.
The apt.dat file gets update with this as well. Here it remains for the navdb parser to understand the 8.33kHz frequencies.
 
WS3.0 also offers the opportunity for well performing ortho scenery with acceptable memory impact. merspieler has acquired GPL compatible sources so we could theoretically have a demo area with ortho scenery in the first WS3.0 release. It adds significant storage requirement tho (~14.7GB per 1x1 degrees tile). There hasn't been a decision made yet, on how to proceed on this.


|background-body =
|background-body =
Line 56: Line 62:
:;Global Land Cover:: https://lcviewer.vito.be/
:;Global Land Cover:: https://lcviewer.vito.be/
:;Natural Earth:: https://www.naturalearthdata.com/
:;Natural Earth:: https://www.naturalearthdata.com/
:;OpenStreetMap :: https://www.openstreetmap.org (See https://sourceforge.net/p/flightgear/fgmeta/ci/next/tree/ws30/ genroads.py, gencoastline.py, genwater.py for details)
|status-body =


|status-body =
As of 11/2020, Stuart pushed a commit that renders VirtualPlanetBuilder output in
FlightGear via the Effects framework.


Below is a screenshot showing Edinburgh using WS3.0:
As of 11/2021, WS30 is available on "next", and on the [https://download.flightgear.org/builds/nightly/ nightly builds].  


[[File:Edinburgh_rendering_using_WS3.0.jpg|thumb]]
Scenery is available for Scotland, but must be downloaded directly (https://drive.google.com/file/d/1tGXSI8RwQxFL0_AFhXaFRVA6go-u7YBW/view?usp=sharing). You need to add the downloaded and then extracted folder as additional scenery folder.


While graphically reminiscent of FlightGear circa 2002 and not particularly
WS30 can be enabled from the Rendering Options menu, with fine-tuning from the LoD menu. Alternatively you can set --prop:/scenery/use-vpb=true to enable it as command line option.
exciting, this is another step towards WorldScenery 3.0.


One of the key differences of WS3.0 from the current scenery is that the
Airports are currently in the old WS2 format - including airport keep terrain. The WS30 terrain goes under the airport so it is not visible.
terrain mesh only consists of elevation data. The landclass information is
encoded in a texture rather than the mesh itself.  So we can have much more
detailed landcover information without massively increasing the size of the
mesh.


In the linked picture, a simple fragment shader is used to look up the
Roads are implemented. Lights on roads are implemented - to see, set time to night. WiP rendering.
landclass in the texture and use that to identify whether to use water,
grass or city textures.<ref>https://sourceforge.net/p/flightgear/mailman/message/37146562/</ref>


As of 08/2020, it's work in progress, and not ready yet.  A very primitive implementation/hack was checked in, but it has limited usefulness in its current state.  It's of no use at the moment unless you build some terrain via VPB to play with. Progress is slow at the moment due to limited time. <ref>https://sourceforge.net/p/flightgear/mailman/message/37074319/</ref>
Vegetation is available - initial version.


While large water bodies are defined in the landclass texture, rivers are draped on top from OSM data.  Coastlines are taken from OSM by are applied as a higher resolution overlay texture to reduce the tiling effect.


To use VPB scenery:
Scenery generation workflow is at an advanced stage. It's fast to build. Scott was able to do UK in a matter of hours [https://sourceforge.net/p/flightgear/mailman/message/37259618/]. People interested in generating scenery for the World Build, or getting their landclass or elevation work on [[Suggested custom scenery|custom scenery]] in, should start learning the tools and process. The exact VPB settings and scenery file format may change several times before the final build. But the process of getting work in to shouldn't change much for scenery creators. See the [[Virtual Planet Builder]] page for instructions.
* Create each 1x1 degree separately with a filename of "<nowiki>WS_[E|W]n[N|S]m.osgb</nowiki>".  Note that this different to the naming format for terrasync and that the numbers are not "0" padded.  E.g. "WS_W3N56.osgb"
* Put the files (along with their subdirectories containing the sub-tiles!) in a "vpb/" subdirectory of a Scenery directory. E.g.
** Scenery/Objects
** Scenery/vpb
* Start FlightGear with "--prop:/scenery/use-vpb=true"


====Scenery generation tool availability ====
* [[VPB]]: '''Linux:''' build from source, docker image available. '''Windows and Mac:''' build from source, no binaries yet, needs NVTT binaries - see "[[Mailing lists|fg-devel]]" mailing list to assist.
* [[QGIS]]: Not needed when experimenting with terrain generation using lower res landclass rasters provided by CORINE. '''Linux:''' build from source, binary packages[https://qgis.org/en/site/forusers/download.html], official docker release available: https://hub.docker.com/r/qgis/qgis  but Fahim was not sure easy the GUI is to use [https://sourceforge.net/p/flightgear/mailman/message/37381800/]. '''Windows, Mac:''' official QGIS binary releases [https://qgis.org/en/site/forusers/download.html].
===LoD settings===
Go to ''View > Adjust LoD > World Scenery 3.0 section'' (Nov 2021).
* 7 LoD levels - most detailed is 6, shown at closest range. Least detailed is 0, shown at long range. LoD 0 tiles with Scotland scenery are 1x1 degree, or approx 111 km x 111 km at the equator.
* Scenery is divided into chunks called tiles. As view distance increases, tiles with a LoD level are replaced by tiles with the next lowest LoD level. e.g. Four LoD 6 tiles are replaced by one LoD 5 tile. Four LoD 5 tiles are replaced by one LoD 4 tile. As view gets closer the reverse happens. One LoD 2 tile is replaced by four LoD 3 tiles.
* Detail range - The LoD level below which each type of feature is not visible. e.g. setting vegetation to LoD 3 means vegetation is shown for LoD 3/4/5/6 and not shown for tiles with LoD 0/1/2.
* Minimum line feature width (line features are things like roads or rivers) - for every LoD level, the width in meters below which a line feature is not shown. e.g. setting LoD level four to 30 meters means rivers or roads that are narrower than 30 meters are not shown for level four tiles. The minimum widths should stay the same or decrease when going down a LoD level.
* Minimum area feature width (area features are things like lakes) - similar to minimum line feature width, but for area in square meters. Setting LoD 3 to 100 square meters means lakes of size 99 square meters or 40 square meters will not show for LoD level 3 tiles.




Line 143: Line 149:
The northern hemisphere, up to N60, has been completed. The southern hemisphere, above S56, has been completed.
The northern hemisphere, up to N60, has been completed. The southern hemisphere, above S56, has been completed.
SRTM data was not captured above N60 and below S56, so alternative data sources need to be procured.
SRTM data was not captured above N60 and below S56, so alternative data sources need to be procured.
Stuart has made good progress with the procedure needed to convert apt.dat into an airport object. Our goal is to utilize this to project/drape the airport layout over the terrain. This will enable localized edits of airports without requiring us to generate another world scenery build.


Oceans are complete.
Oceans are complete.

Latest revision as of 23:12, 21 December 2023

World Scenery 3.0
Started in 2019-Sep
Description New world-wide scenery
Contributor(s) Scott Giese
Richard Harrison
Stuart Buchanan
Status Active [1]

Motivation

1rightarrow.png See Virtual Planet Builder for the main article about this subject.

Cquote1.png Virtual Planet Builder (VPB) is OSG's terrain-database-building tool.

It loads GIS elevation data for a region, combines it with imagery and produces a spatially-balanced quadtree tiled database that can be navigated simply by loading the top-level file. All of the LOD Ranges are pre-configured and the DatabasePager automatically loads and unloads different segments of terrain without any supporting userspace code required. VPB can build terrain models ranging from a small area to the entire planet. These databases can be fluidly navigated at 60fps from outer space down to ground level with no interruptions. The terrain models are built of regular grid arrays with optional edge-skirts to conceal any cracks caused by adjacent LOD differences.


OpenScenGraph's Virtual Planet Builder/OSGDEM. Published by AlphaPixel, LLC.
(powered by Instant-Cquotes)
Cquote2.png

Objective

Initial rendering of Edinburgh scenery using a raster landclass and texture lookup for city, water and grass
Screenshot showing a WS2.0 airport .btg file rendered with WS3.0 terrain
WS3.0 Edinburgh airport with runtime-generated roads from OSM data
WS30 view of West Lothian, with 25m resolution landclass data, vegetation, osm2city buildings, and OSM-based roads and rivers.
Edinburgh at night, with osm2city buildings, OSM-base roads, including whether they are lit or not. Note the road in the foreground which is lit near the buildings and unlit in the countryside.
WS30 using OSM data to define the coastline. This shows a view near Oban in Scotland looking South. The coastline is applied as a high resolution overlay texture that is generated at runtime from OSM data and mixed with the landclass texture by the ws30 shader.

Produce high-quality scenery using the best-known practices.

TerraGear becomes obsolete in favor of VPB.

  • OpenGL 3.3 Core Profile: WS3.0 will require us to eliminate the usage of the fixed-function pipeline.
  • Shader-based Rendering: All of the terrain renderings will be done via GLSL shaders.
  • OSG Core: OpenSceneGraph will require targeting of the OpenGL Core Profile.

WS3.0 will continue to cooperate with osm2city.

Easy upgrade: Initially the plan was that airport layouts will be generated in real-time. Apt.dat will continue to be the primary source for airport layouts and that airports will be draped over the terrain. This would eliminate the need to cut airport layouts into the underlying terrain. Due to difficulties with this approach, it has been decided, that we keep using the WS2.0 airports for now. Work has been done to automatically update the airports from the X-Plane gateway which can be done automatically now. The apt.dat file gets update with this as well. Here it remains for the navdb parser to understand the 8.33kHz frequencies.

WS3.0 also offers the opportunity for well performing ortho scenery with acceptable memory impact. merspieler has acquired GPL compatible sources so we could theoretically have a demo area with ortho scenery in the first WS3.0 release. It adds significant storage requirement tho (~14.7GB per 1x1 degrees tile). There hasn't been a decision made yet, on how to proceed on this.

Background

Data Sources

SRTMGL3.003
: https://e4ftl01.cr.usgs.gov/MEASURES/SRTMGL3.003/
SRTMGL1.003
: https://e4ftl01.cr.usgs.gov/MEASURES/SRTMGL1.003/
Global Land Cover
: https://lcviewer.vito.be/
Natural Earth
: https://www.naturalearthdata.com/
OpenStreetMap
: https://www.openstreetmap.org (See https://sourceforge.net/p/flightgear/fgmeta/ci/next/tree/ws30/ genroads.py, gencoastline.py, genwater.py for details)

Status

As of 11/2021, WS30 is available on "next", and on the nightly builds.

Scenery is available for Scotland, but must be downloaded directly (https://drive.google.com/file/d/1tGXSI8RwQxFL0_AFhXaFRVA6go-u7YBW/view?usp=sharing). You need to add the downloaded and then extracted folder as additional scenery folder.

WS30 can be enabled from the Rendering Options menu, with fine-tuning from the LoD menu. Alternatively you can set --prop:/scenery/use-vpb=true to enable it as command line option.

Airports are currently in the old WS2 format - including airport keep terrain. The WS30 terrain goes under the airport so it is not visible.

Roads are implemented. Lights on roads are implemented - to see, set time to night. WiP rendering.

Vegetation is available - initial version.

While large water bodies are defined in the landclass texture, rivers are draped on top from OSM data. Coastlines are taken from OSM by are applied as a higher resolution overlay texture to reduce the tiling effect.

Scenery generation workflow is at an advanced stage. It's fast to build. Scott was able to do UK in a matter of hours [1]. People interested in generating scenery for the World Build, or getting their landclass or elevation work on custom scenery in, should start learning the tools and process. The exact VPB settings and scenery file format may change several times before the final build. But the process of getting work in to shouldn't change much for scenery creators. See the Virtual Planet Builder page for instructions.

Scenery generation tool availability

  • VPB: Linux: build from source, docker image available. Windows and Mac: build from source, no binaries yet, needs NVTT binaries - see "fg-devel" mailing list to assist.
  • QGIS: Not needed when experimenting with terrain generation using lower res landclass rasters provided by CORINE. Linux: build from source, binary packages[2], official docker release available: https://hub.docker.com/r/qgis/qgis but Fahim was not sure easy the GUI is to use [3]. Windows, Mac: official QGIS binary releases [4].

LoD settings

Go to View > Adjust LoD > World Scenery 3.0 section (Nov 2021).

  • 7 LoD levels - most detailed is 6, shown at closest range. Least detailed is 0, shown at long range. LoD 0 tiles with Scotland scenery are 1x1 degree, or approx 111 km x 111 km at the equator.
  • Scenery is divided into chunks called tiles. As view distance increases, tiles with a LoD level are replaced by tiles with the next lowest LoD level. e.g. Four LoD 6 tiles are replaced by one LoD 5 tile. Four LoD 5 tiles are replaced by one LoD 4 tile. As view gets closer the reverse happens. One LoD 2 tile is replaced by four LoD 3 tiles.
  • Detail range - The LoD level below which each type of feature is not visible. e.g. setting vegetation to LoD 3 means vegetation is shown for LoD 3/4/5/6 and not shown for tiles with LoD 0/1/2.
  • Minimum line feature width (line features are things like roads or rivers) - for every LoD level, the width in meters below which a line feature is not shown. e.g. setting LoD level four to 30 meters means rivers or roads that are narrower than 30 meters are not shown for level four tiles. The minimum widths should stay the same or decrease when going down a LoD level.
  • Minimum area feature width (area features are things like lakes) - similar to minimum line feature width, but for area in square meters. Setting LoD 3 to 100 square meters means lakes of size 99 square meters or 40 square meters will not show for LoD level 3 tiles.


Proof of Concept 100}% completed

  • VPB Done Done
  • osgOcean Done Done
  • osgVegetation Done Done
  • Generate terrain for Hawaii Done Done
  • Hack Hawaii VPB into FG Done Done


OSG 70}% completed

  • Core Profile: Done Done
  • GLVND Support: Done Done
  • glTF Plugin Support: Ongoing Ongoing


Standard-Fidelity
N00-N60 lat  
Africa Land Coverage  
Natural Earth  
Ocean Fill  

Standard-Fidelity - 90m SRTMGL3 - 100m Global Land Cover

Northern Hemisphere: 152.3 GB

Southern Hemisphere: 57.4 GB

Virtual Planet Builder 70}% completed

  • Procure Demographic Data: SRTMGL3.003 Paused Paused
    • Northern: 70}% completed
    • Southern: 70}% completed
  • Process through VPB Paused Paused
    • Northern: 70}% completed
    • Southern: 70}% completed
  • Ocean Done Done
    • Northern: 100}% completed
    • Southern: 100}% completed


High-Fidelity - 30m SRTMGL1 - Best Available Land Cover

Virtual Planet Builder 30}% completed

  • Procure Demographic Data: SRTMGL1.003 Paused Paused
    • Northern: 70}% completed
    • Southern: 0}% completed
  • Process through VPB Paused Paused
    • Northern: 70}% completed
    • Southern: 0}% completed


News / Updates

The northern hemisphere, up to N60, has been completed. The southern hemisphere, above S56, has been completed. SRTM data was not captured above N60 and below S56, so alternative data sources need to be procured.

Oceans are complete.

Changelog

Gallery

Roadmap

Template:Roadmap

Related

Standard-Fidelity Gallery
WS3 Terrain Mesh  
Asia/India  
Europe  
USA  
Land Coverage  
Natural Earth  
Natural Earth  

For the experimental runtime generated mesh/landclassing engine - which may become WS3.0 - see Experimental terrain engine.