Message 1 of 2
Getting the outline of door/window opening in a floor plan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
I'm a beginner in the API and I'd like to have an opinion on a problem I'm encountering.
I want to get a curveloop of the outline of a door/window opening in the host wall in a floor plan.
Goal : Draw a floor whose shape includes the room + the doors/windows in the room.
I've tried the method : ExporterIFCUtils.GetInstanceCutoutFromWall but i didn't achieved to get the loop on a floorview, only on an elevation/section view.
Currently, i'm trying to draw the opening using some values but i don't think it's the right method to use (code below).
CurveLoop get_instance_loop(FamilyInstance door)
{
Document doc = door.Document;
CurveLoop loop = null;
Wall wall = door.Host as Wall;
double door_width = door.Symbol.LookupParameter("Width").AsDouble();
double wall_width = wall.WallType.Width;
LocationPoint pos = door.Location as LocationPoint;
XYZ orientation = wall.Orientation;
//Create a rectangle using the values
return loop;
}
What do you think ? Am i on the right path ?
Tks,
Lorenzo