A UNIFIED APPROACH FOR 3D GENERALIZATION OF BUILDING MODELS IN CITYGML

: Task-specific applications demand abstractions (generalized) 3D scenes of 3D models to be used for visualization and analysis purposes. Therefore, lower LoDs (level-of-details) from higher LoDs need to be made available to these applications. A unified generalization framework is proposed to derive multiple LoDs (LoD3-LoD1) taking both semantics and geometric aspects of 3D buildings modelled in CityGML (City Geography Markup Language) into account. For this purpose, interior structures of 3D objects at LoD4 are removed to derive LoD3 and openings (door, windows) are removed from LoD3 to derive LoD2. Remaining parts such as outer installations and walls are projected onto the ground and simplified based on CityGML generalization specifications. Algorithms for simplification with the aim to derive LoD1 from LoD2 are implemented and tested on a number of buildings of Putrajaya city, Malaysia.The experiments shows that elimination of important part (s) or merging could be avoided by applying semantic-based removal of objects at different LoDs.


INTRODUCTION
Task-specific applications demand abstractions (generalized) 3D scenes of building models to be used for visualization and analysis purposes.Therefore, lower levels-of-details (LoDs) need to be produced from higher LoDs of 3D models to fulfill the demand of these applications.However, main characteristics of the buildings need to be preserved.Some disaster management related applications may request to maintain outer installations of building, openings (e.g.doors, windows) to assess potential affected features of a building.For this purpose, LoD2 can be derived from LoD3 upon a user request.Similarly, for navigation systems, some specific attributes e.g.outerbuilding-installations and openings are not required so they can be detached from building.Tourism-related applications may require preserving specific types of building models and their components such as entrances of a museum for visitors, exit points of sport complex, castle, etc.The queries might be e.g."exit points should be maintained", "windows should be removed".Therefore, generalization strategy could be customized to fulfill demands of specific demands of users' or applications and attached features can be removed.Generalization strategies vary with the aim to derive different LoDs to fulfill the demand of applications or users and depend on the type and the structure of building models.Additionally, generalization strategy taking semantics into account can fulfill such demands of applications or users.
The building model is the most detailed thematic concept of CityGML (City Geography Markup Language) (Gröger et al., 2007).It allows the representation of thematic and spatial aspects of buildings, building parts and installations in four LoDs (LoD1 -LoD4) but it doesn't provide methods to generate different LoDs automatically.Therefore, generalization of buildings modeled and represented in CityGML with structured geometry along with rich semantics at different LoDs (LoD1-LoD4) is initiated to derive multiple LoDs.Because, building modeled in CityGML can easily be decomposed and inter-link building models based on their semantics such as BuildingParts, Rooms, WallSurfaces, etc. and geometric structures into CompositeSurfaces (Kolbe et al., 2009b).A number of researchers e.g.(Fan et al., 2009) and(Mao et al., 2011) suggested that both, geometry and rich semantic information attached with 3D buildings modelled in CityGML should be taken into account while generating multiple LoD.But much of semantic data and main characteristics of building models could be lost during the generalization and conversion process from CityGML files to another visualization standard e.g.X3D.A novel for multiple representation data structure for dynamic visualization of 3D city models taking semantic information into account has been proposed in (Mao et al., 2011) and produced CityTree to store different LoDs of generalized models.Data was lost due to conversion between CityGML and X3D.They suggested that the derived LoD2 is more generalized than LoD3 hence the process for deriving LoD2 from LoD3 is relatively more complicated than deriving LoD1 from LoD2.
Similarly, some applications or users may be interested to preserve size of walls or outer installations smaller or larger than a certain threshold.Therefore, simplification process could be tailored to receive input from a user or an application.In this case, simplification operation could be initiated to reduce length of walls etc.In case of buildings modeled in CityGML, generalization based on geometric transformation of edges of building models with the aim to reduce data volume from each LoD can be applied to associated geometries.For this purpose, four decades ago, research done on a set of generalization procedures in (Staufenbiel, 1973) for geometric transformation of 2D ground plans were based on reducing length of larger features randomly.Similarly, a number of algorithms were proposed to remove line segments of ground plan by extending and crossing their neighboring segments (Powitz, 1973, Regnauld, 2001) but removal of line segments based on selfperceptual rules could affect topology and shape of neighbouring segments.This could produce different results.Similarly, research study by (Sester, 2005) suggested that the fundamental control parameter of the proposed method is the minimal length of a building façade which can be perceived suitable in the generalized representation.Here, she made minimum length as criteria for simplification process without assigning a value.Similarly, for better visual impression, different angles and values for minimum distances have been used as a threshold by different researchers so the results become different from each other.Therefore, main characteristics of buildings could not be maintained and even important features could be eliminated or merged.
Simplification method proposed in (Sester and Brenner, 2004) and extended by (Fan et al., 2009) and(Mao et al., 2011) based on CityGML specification is suitable for simplification of 2D plans but could produce different results as simplification is carried out without taking differential changes and ratios into account.This year's research conducted in (Fan and Meng, 2012) is related to simplification of simple structures like parallel and rectangle shapes and also complicated structures like non-parallel, non-rectangular and long narrow angles shapes.However, differential changes, and ratio of changes based on an internationally agreed standard for minimum length for simplification need to imposed during simplification process.Additionally, additional bumps could be generated prior to simplification process to maintain the pattern (clockwise or anti-clockwise) made by equal corners and parallel sides (Baig and Rahman, 2013).
This approach is an extension of our previously investigated work (Baig and Rahman, 2013) related to another method for generalization and visualization of 3D buildings modeled in CityGML.The previous approach dealt only geometric aspects of 3D building models while performing generalization operations.This approach is a combination of both, removal of components such as interiors at LoD4, openings at LoD3 based on semantic information and geometric transformation of permanently attached components like walls and antennas, etc. based on geometry information similar to (Fan and Meng, 2009).Additionally, minimum length of edge for geometricbased simplification process is restricted to CityGML generalization specifications.This could maintain accuracy of generalized objects.Simplification process of two cases of features containing off-sets and corners are described to extend larger length of edge and to remove smaller one.Connected geometric structures are simplified taking differential changes and ratios into account.Algorithms for simplification with the aim to derive LoD1 are implemented and tested on a number of buildings of Putrajaya City of Malaysia.
The proposed study is expected to give semantic and systematic understanding on unified approach of 3D generalization based on semantic and geometric information.The study could assess the capabilities of CityGML to represent different LoDs of 3D building models.Initially, buildings modeled in CityGML and its generalization specifications are discussed in Section 2. Methodology for a unified 3D generalization approach is discussed taking geometric and semantics of 3D building models into account in Section 3. Finally, implementation and results were discussed in Section 4 followed by conclusion in Section 5. Maximum paper length is restricted to 6 printed pages.Invited papers can be increased to 12 pages.The paper should have the following structure:

Buildings Modelled in CityGML
Both, geometry and semantics are logically represented and linked on different LoDs so that relationship between geometry and semantic could be established.Structured geometry models with rich semantics comprised of ontological structure including thematic classes, attributes, and their interrelationships besides the spatial and graphical aspects (Kolbe et al., 2009b).Such models are the most detailed thematic concept of CityGML (Gröger et al., 2007).Single building modeled in CityGML may have multiple spatial representations in different levels of detail at the same time .An individual geometry representation is provided for each of the four levels of detail (LoD1 to LoD4).Structured geometric models along with rich semantics at different LoDs (LoD1 -LoD4) are presented in Figure 1.
At LoD1, a building model consists of a geometric representation of the building volume.In LoD2, geometric representations such as MultiSurface and MultiCurve geometries are used for modeling architectural details like a roof overhang, columns, or antennas.Other higher LoDs, the outer facade of a building are differentiated semantically by the two classes such as _BoundarySurface and BuildingInstallation.The first class is a part of the building's exterior shell with a special function like wall (WallSurface), roof (RoofSurface), ground plate (GroundSurface) or ClosureSurface and may have the attributes class, function and usage.The second class is used for elements of building like balconies, chimneys, dormers or outer stairs, strongly affecting the outer appearance of a building.The openings in _BoundarySurface objects (doors and windows) can be represented as thematic objects in LOD3 while the interior of a building, composed of several rooms, is represented in the building model by the class Room in LoD4.Additionally, interior installations of a building, such as objects within a building which (except furniture) cannot be moved, are represented by the class IntBuildingInstallation.

Coherent Modelling
Coherent modeling of semantics and geometrical/topological properties is an important design principle of CityGML (Kolbe et al., 2009b).Real world entities are represented by features like building, wall, window or room at the semantic level while spatial location and extend of thematic features is assigned a geometry at geometric level.A relationship between geometry and semantics of a whole building and building part is maintained and the associated geometries for single building with gabled roof at LoD2 (lod2Solid), roof (exterior associated with polygon and LinearRing) etc. are associated.Therefore, models with structured geometry along with rich semantics can easily be processed by generalization strategies to derive multiple LoDs.

City generalization specifications
CityGML generalization specifications provided for different LoDs are characterized by differing accuracies and minimal dimensions of objects.IntBuildingInstallations composed of interior stairs, railings, radiators or pipes, which are permanently attached to the building structure cannot be removed directly so are considered to be part of LoD3.However, objects of the class IntBuildingInstallation can either be associated with a room (class room), or with the complete building / building part.

Derivation of LoD2 from LoD3
After derivation of LoD3 from LoD4, the resulting object classes at LoD3 composed of OuterBuildingInstallation, Wall, Roof, and Openings (Door, Window).With the aim to derive LoD2 from LoD3, openings are removed while other outer installations are projected onto the ground for simplification purpose.OuterBuildingInstallation class is related to outer components of a building therefore strongly affects the outer characteristic of the building.This class object contains chimneys, stairs, antennas, balconies or attached roofs above stairs and paths.These components are removed with the aim to produce LoD2 if the length and height of components of OuterBuildingInstallation is less than 4m.Otherwise, they are preserved at LoD2.

Derivation of LoD1 from LoD2
Structural features of building models need to be clubbed and formed a simple block at LoD1.Positional and height accuracy of edges of footprints must be less than 6m at LoD1.Therefore, lengths of footprints of polygons of objects less than 6m x 6m are removed directly.Otherwise, simplification process is initiated followed by aggregation of simplified blocks.The resulting LoD1 become a building block without roof in proper shape, and simplified walls as flat plane.Therefore, derivation of LoD1 from LoD2 is considered as a process of simplification and aggregation of features in LoD2.The height of all walls becomes same and size of roof plane remains same to floor plan of building model.For this purpose, exterior shell from LoD3 can be extracted and closed polygon is formed as a solid block model.

Simplification of components projected onto the ground
At LoD3, opening objects such as windows and doors are removed and remaining objects are projected onto the ground as footprints.Two case studies are presented with the aim to simplify projected ground plans based on CityGML generalization specifications.For this purpose, an adoption of methods for simplification proposed in (Sester and Brenner, 2004) and adopted by (Fan et al., 2009) is applied in Case 1.
The minimum length of edges considered to be removed at LoD3 and LoD2 are 4m while 6m respectively.Algorithms described in both cases (I, II) for simplification with the aim to derive multiple LoD1 and LoD2 are implemented and tested on a number of buildings of Putrajaya City of Malaysia.

Case I. Removal of off-sets
Asymmetrical features contain irregular shapes of edges.
Initially, the nature of shape of a polygon is checked to determine the type of intrusion or extrusion it contains before simplification process starts.Secondly, lengths of all edges of polygons are calculated and compared with minimum criteria for LoD2 (>4m) and LoD1 (>6m) described by CityGML.Simplification process of asymmetrical edges taking minimum length of smaller edge into account is presented in Figure 3.All shortest edges less than threshold are removed in two iterations in this case.It is necessary to make sure that there is no important part of building lies on any asymmetrical edges  Complex buildings maintain interconnected features with complex geometries.Additionally, each polygon maintains a relationship with other connected polygon.So, changes in smaller or larger polygons have an effect on both features as most of these polygons share certain edges and nodes.For example, a slight change in the length of a of commonly shared wall of the house and a garage can affect the shape and size of the garage so differential changes and ratios of changes in both structures cannot be ignored.Simplification of such a case is made in Figure 4, where an object having three connected edges of a polygon of a wall are represented as , and .
Coordinates of nodes of these edges have been presented as ( ,  The ratio of differential changes as and and changes in the length along x-axis and y-axis are given in following equation: (1) Slight changes ( and ) along with axis's can be calculated applying this equation: ( (3) Based on the above-mentioned subfigure in (a), length of base of triangle is represented as .The length of newly formed polygon is calculated given equation: (4) where x, y = node's coordinates

IMPLEMENTATION AND RESULTS
Our research focused on derivation of multiple LoDs of buildings modeled in CityGML taking semantics and geometric transformation of permanent objects into account.Their associated solid geometries such as LinearRing composing the boundary of the surface object (which also might be a CompositeSurface and MultiSurface) are stored along with their corresponding coordinates.Secondly, objects or object parts and their corresponding geometry is retrieved from database and stored in a data structure developed in Visual C++.
Implementation of generalization process is divided into two parts.(1) Removal of building parts and installations in four levels of detail, LoD1 to LoD4 from data structure.Figure 5 shows the result of derived LoDs (LoD4 to LoD1) of a single building model.( 2) Implementation of geometrictransformation of roof overhangs, antennas, and other outer building installations which were permanently attached with semantic objects are simplified using CGAL library.Data structures are created and algorithms for arrangements of edges, geometry processing and convex hull algorithms of CGAL library.Decomposed 3D building components down to the level of vertexes are stored in data structures and algorithms operate on nodes of polygons of ground plans and performed geometric tests on them.Lengths and locations of nodes of polygons of complex structures were analyzed.Length of each edge was calculated based on x and y coordinates of nodes and stored in a variable temporarily to be used to determined shortest parts.Each edge of polygon is checked to determine whether it is smaller than CityGML defined (minimum length of edge > 4m at LoD2 and >6m at LoD1) and removed or preserve based on the criteria.Algorithms presented in Case I and Case II were implemented and tested on a number of buildings of Putrajaya city of Malaysia with the aim to derive LoD1.Simplified models at LoD1 of buildings at Putrajaya city is presented in Figure 6.

CONCLUSION
Redundancy due to repetition of coordinates of commonly shared nodes of exterior within CityGML file increase the size of file and takes much time during loading, parsing and rendering.However, generalization followed by compression of models can help to transport heavy file for online visualization.Removal of objects based on semantics and CityGML-based standard criteria to remove smaller edges of objects with the aim to preserve original shape is one of the strengths of unified approach.Quite complex algorithms could be needed to extract outer shell and could become time consuming.Therefore, only coordinates of nodes of outer shell of 3D building models were separated and parsed to populate objects.Therefore, important data as well as topological connection between polygons of buildings could be lost during separation of objects contain nodes of 3-D building outer shell.Another reason to separate outer shell offline was because of redundancy due to repetition of coordinates of nodes of 2D planes within CityGML file.Therefore, the size of CityGML file becomes heavy due to this repetition and rendering time could be increased.However, generalization followed by compression of models can help to transport heavy file for online visualization.Iterations should be made flexible based on user input or applications' demand to provide minimum length of edge to be considered for simplification process.CityGML-based standard criteria to remove smaller components of building with the aim to preserve original shape are one of the strength of algorithms.Removal of important features can be avoided.The results were visualized in LandXplorer CityGML Viewer 2009 so desktop visualization of generalized 3-D building models is one of the drawbacks of this study.Further research to visualize generalized objects from a newly developed data structure to store generalized LoDs as multiple data structure could be used for real-time visualization.Additionally, based on visual perception, building closer to viewing point of a user could be made less generalized as compared to those locating far from user in street view.

Figure 1 .
Figure 1.Examples of structured geometric models (Gröger et al., 2007) along with rich semantics at different LoDs (LoD1 -LoD4) ).However, a larger non parallel edge (red) share an edge with another non parallel edge (blue) shown in (b).Simplification method is designed in such as way that creation of new corners or intrusion/extrusion could be avoided.If both non parallel larger edges () and ( ) are extended till their intersection then a new corner could be produced.Therefore, (red) is extended until it intersects with (blue) so another irregular shape (dotted line) is produced.Subsequently, the resulting polygon highlighted in dotted lines is removed resulting a new edge represented as (red) in (c).Result of simplification process with second iteration is presented in (e).

Figure 3 .
Figure 3. Simplification of asymmetrical edges of ground plan with two iterations.Result of 1 st iteration after removing shorter edges (c) and in 2 nd iteration, their transformation results (e) Case II: Adjustment based on and to tailor with formulas given below.When the size of the larger edge in (a) is slightly decreased then the smaller edge of polygon is effected as nodes of both polygons are connected.A slight change along with x-axis is presented by and along with y-axis by as differential changes.Due to dependency, a ratio can be established between lengths of and .

Figure 4 .
Figure 4. Simplification of three jointly attached edges of a polygon: Reduction of shortest edges based on differential changes shown in (b) and simplified polygons as final result in (c).
Table1shows all object blocks as generalized features with ground plans of at least 6m * 6m have to be considered in LoD1 while 4m*4m in LoD2.In the detailed model at LoD3, the minimal size of edge of generalized object should be 2m*2m.Simplification method described in next section follows these rules.Minimum length of edge considered for simplification process in our case is based on CityGML generalizations specifications.Initially, the polygons belonging to openings are removed followed by filling of resulted holes.Corresponding ground plans of components of buildings are simplified.Distinctive roof structures are projected onto the ground similar to walls and openings and simplified.Smaller components less than CityGML generalization specifications are detected and eliminated.
3.1 Derivation of Multiple LoDsEntire geometries and semantics are transferred from upper LoD to lower LoD with the aim to derive multiple LoDs.
The generalization process is implemented in Visual C++.The platform used for generalization process is Visual Studios version 2008 operated on a Dual-Core CPU 2.10 GHz, 4.00 GB RAM.Initially, a number of tables are created in a relational 3D Geodatabase to store semantic objects and object parts such as (doors, windows, etc.) and their corresponding geometries (solids) of a building retrieved from XML-based CityGML file.Relational table containing objects and object parts are interlinked with associated geometry (solids) stored in a separate table.These object parts include interior building installations, building furniture, room installations, and interior of room, outer building installation, walls, roofs and openings (door, window) are stored in a data structure representing LoD4.For example, in LoD3, corresponding geometry of the openings (doors, windows) are represented as BoundarySurface as thematic objects.Similarly, this geometric representation is refined in LoD2 by additional MultiSurface and MultiCurve geometries, used for modeling architectural details like a roof overhang.