Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question

Revision history [back]

As @Stuart Dols mentioned, there is an OpenStudio Method to do this.

space = OpenStudio::Model::Space::fromFloorPrint(point3dVector, hight_m, model)

point3DVector is your polygon. You could use an OSM file format as your starting point and then convert to IDF when you want to do model manipulation outside of OpenStudio. You can also write an EnergyPlus measures, that takes in and passes out an IDF file, but under the hood makes a temp OSM file to create the envelope, and then converts it to IDF with the measure. You can see this in context in the Bar Aspect Ratio Study measure.

Here is the API documentation for the method

You could loop through multiple polygons (for core and perimeter zoning) and then run surface matching, and add windows and overhangs if you want. Could also make multi-story.

As @Stuart Dols mentioned, there is an OpenStudio Method to do this.

space = OpenStudio::Model::Space::fromFloorPrint(point3dVector, hight_m, model)

point3DVector is your polygon. You could use an OSM file format as your starting point and then convert to IDF when you want to do model manipulation outside of OpenStudio. You can also write an EnergyPlus measures, that takes in and passes out an IDF file, but under the hood makes a temp OSM file to create the envelope, and then converts it to IDF with the measure. You can see this in context in the Bar Aspect Ratio Study measure.

Here is the API documentation for the method

You could loop through multiple polygons (for core and perimeter zoning) and then run surface matching, and add windows and overhangs if you want. Could also make multi-story.

As another options, if your building footprints happen to be in geo-json format, there are methods available to import those into OpenStudio. This un-supported measure I posed as an example does the opposite, but I thought the code in it maybe useful. It converts footprint of OSM to geo-json text. I was using it to place OSM's into an urban environment