Commit 2598260a authored by Rick Gruber-Riemer's avatar Rick Gruber-Riemer

Change in FLAG naming and introduce new FLAG_STG_BUILDING_LIST

parent 4b0f176e
......@@ -204,7 +204,7 @@ if __name__ == '__main__':
configure_logging(my_log_level, args.log_to_file)
if parameters.FLAG_2018_3:
if parameters.FLAG_COLOUR_TEX:'Processing for 2018.2 version')
exec_procedure = Procedures.all
......@@ -547,7 +547,7 @@ class Building(object):
logging.debug("__done" + str(self.roof_texture) + str(self.roof_texture.provides))
if parameters.FLAG_2018_3:
if parameters.FLAG_COLOUR_TEX:
if s.K_BUILDING_COLOUR not in self.tags:
if s.K_ROOF_COLOUR not in self.tags:
......@@ -842,7 +842,7 @@ class Building(object):
# now apply some tags to increase European style
if s.K_ROOF_COLOUR not in self.tags:
if parameters.FLAG_2018_3:
if parameters.FLAG_COLOUR_TEX:
self.tags[s.K_ROOF_COLOUR] = '#FF0000'
self.tags[s.K_ROOF_COLOUR] = 'red'
......@@ -1450,7 +1450,7 @@ def write(ac_file_name: str, buildings: List[Building], cluster_elev: float, clu
colours_index += 1
materials_list = list()
if parameters.FLAG_2018_3:
if parameters.FLAG_COLOUR_TEX:
texture_name = 'FIXME' # FIXME: this is only temporary until we have new textures
materials_list = mat.create_materials_list_from_hex_colours(colours)
......@@ -1465,7 +1465,7 @@ def write(ac_file_name: str, buildings: List[Building], cluster_elev: float, clu
ac_object = lod_objects[b.LOD]
face_mat_idx = 1 # needs to correspond with with a material that has r, g, b = 1.0
roof_mat_idx = 1 # ditto
if parameters.FLAG_2018_3:
if parameters.FLAG_COLOUR_TEX:
face_mat_idx = colours[b.tags[s.K_BUILDING_COLOUR]]
roof_mat_idx = colours[b.tags[s.K_ROOF_COLOUR]]
b.write_to_ac(ac_object, cluster_elev, cluster_offset, roof_mgr, face_mat_idx, roof_mat_idx, stats)
......@@ -97,8 +97,11 @@ Important Flags
============================================= ======== ======= ==============================================================================
Parameter Type Default Description / Example
============================================= ======== ======= ==============================================================================
FLAG_2018_3 Boolean False If True then then the texture catalog and shader integration is for minimal
version of FlightGear 2018.3.
FLAG_COLOUR_TEX Boolean False Experimental code. If True then the texture and OSM tags can use
colouring. For later versions of FlightGear (2019.x?).
FLAG_STG_BUILDING_LIST Boolean False Experimental code. If True then some buildings use the Random Building
code in FlightGear instead of a building mesh.
BUILDING_USE_SHARED_WORSHIP Boolean False Use a shared model for worship buildings instead of OSM floor plan and
heuristics. The shared models will try to respect the type of building (e.g.
......@@ -79,7 +79,7 @@ USE_EXTERNAL_MODELS = False
FLAG_2018_3 = False # Feature flag for 2018.1 or greater version of FG
FLAG_COLOUR_TEX = False # Feature flag for using colour codes in textures and OSM tags
# Debugging by plotting with Matplotlib to pdfs. See description about its use in the appendix of the manual
......@@ -67,7 +67,7 @@ def screen_osm_keys_for_colour_material_variants(tags: Dict[str, str]) -> None:
del (tags[wrong])
# now make sure that the values are correct
if parameters.FLAG_2018_3:
if parameters.FLAG_COLOUR_TEX:
if 'building:colour' in tags:
tags['building:colour'] = map_osm_colour_value_to_hex(tags['building:colour'], True)
if 'roof:colour' in tags:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment