public static BHS.Level FromTAS(this TAS3D.Floor tbdFloor) { BHS.Level level = new BHS.Level(); level.Name = tbdFloor.name; level.Elevation = tbdFloor.level.Round(); return(level); }
public static TBD.BuildingStoreyClass ToTAS(this BHS.Level level) { TBD.BuildingStoreyClass tbdLevel = new TBD.BuildingStoreyClass(); if (level == null) { return(tbdLevel); } //Hard to build the tbdLevel when the BHA Level does not store any geometry information at this stage... return(tbdLevel); //ToDo: do this better with geometry information from somewhere else... }
public static BHS.Level FromTAS(this TBD.BuildingStorey tbdStorey) { BHS.Level level = new BHS.Level(); if (tbdStorey.GetPerimeter(0) != null) { BHG.Polyline levelCurve = tbdStorey.GetPerimeter(0).FromTAS(); double elevation = levelCurve.ControlPoints.First().Z; level.Name = "Level " + elevation.Round(); level.Elevation = elevation.Round(); } return(level); }