cityImage.polygon_2d_to_3d#
- cityImage.polygon_2d_to_3d(building_polygon, base, height)[source]#
Convert a 2D polygon to a 3D polygon. This function takes a 2D polygon (building_polygon) and extrudes it into 3D space, creating a pv.PolyData, creating a 3D polygon with a base and a height elevation.
- Parameters:
(shapely.geometry.Polygon) (building_polygon) – 2D polygon to be extruded.
(float) (height) – Base height of the 3D polygon.
(float) – Height of the 3D polygon.
Returns –
---------- –
pv.PolyData – A 3D polygon.