py4design.massing2citygml module

class py4design.massing2citygml.Massing2Citygml

Bases: object

An object that extracts all the neccessary information from a massing model and converts the geometries into CityGML objects with semantics, only works for LOD1 CityGML models. For more information please refer to Chen, Kian Wee, Patrick Janssen, and Leslie Norford. 2017. Automatic Generation of Semantic 3D City Models from Conceptual Massing Models. In Future Trajectories of Computation in Design, Proceedings of the 17th International Conference on Computer Aided Architectural Design Futures, pp 84 to 100. Istanbul, Turkey.

Attributes

occshp_attribs_obj_list (list of ShapeAttributes objects) The geometries are first converted to ShapeAttributes objects before into CityGML object. ShapeAttributes is an intermediate format.
template_rule_obj_list (list of BaseTemplateRule class instances) The template rules for converting the geometries.
read_collada(dae_filepath)

This function reads the Collada (.dae) file to be converted and convert the geometries to ShapeAttributes objects.

Parameters:

dae_filepath : str

The file path of the Collada file to be converted.

add_template_rule(template_rule_obj)

This function adds BaseTemplateRule objects to this class.

Parameters:

template_rule_obj : implementation of the BaseTemplateRule meta class

The template rule used for converting the geometries to semantic models.

execute_analysis_rule()

This function adds executes the analysis rules in the template rules and append the analysis results to the ShapeAttributes objects.

execute_template_rule(citygml_filepath)

This function executes the template rule and convert the geometry to semantic models.

Parameters:

citygml_filepath : str

The file path of the resultant CityGML file.