Thanks for the advice.
The issue is I can’t work out a way to find/generate the loops. It just gives me all the lines of the Area Boundary as a list. How do I generate separate polycurves for each loop? Every way failed.
Triming is quite possible only when I can have the distinct loops for each area right?
You will possibly find different solutions for that but one of them would be to use the OOTB PolyCurve.ByJoinedCurves node and/or Group Curves from Archilab.
Oh I have tried all sort of grouping and making point loops… simplifying them… literally everything.
PolyCurve.ByJoinedCurves was literally the first thing I tried.
Did you try Archilab nodes?
There are also a couple of options to be found through the search field:
Oh yes I did try that too.
Th only partial success I found was from Ampersands polycurvebycurve but it still fails in multiple cases.
I am already trying to think of some other way. Maybe generate geometry from the Color Scheme edges. Couldn’t find anything on that too though. Any clue?
Why don’t you use the connected boundaries output on the Collector.Areas node?
Oh that gives null straight away. The way the collector node makes the connected boundaries is pretty inefficient anyways. Thats the primary reason why I am using the Pyhton script rather than using the connected boundaries.
This needs some more details to be understood.
At this stage, I get polygons out of it.
Room.Boundaries from Clockwork works also with the areasElements output.
Then PolyCurve.ByJoinedCurves creates the needed polycurves.
You could maybe need the help of a containment test but I don’t have time to check, see here:
The screen shot in my earlier post is actually a screen shot of how the collector node works. It is just using the Polycurv.byjoinedcurves to make a polygon. It doesn’t really consider cutouts or loops.
the room.boundaries does give the boundaries but the issue is the boundaries for areas dont really need to be joined always. It has a threshold in revit built in so it doesn’t always create a loop… so using the room.boundaries doesnt cut it for me sadly.
Try Surface.ByPatchPolyCurves (Chynamo). Optionally, double-clic on it to see how it’s build…
@Amrit_Banerjee Here is an example with an area with cut outs
Details on the custom node tstngwtrs-GroupCurves can be found here …
Yep it does work like a charm.
Could you mark the post as solved then?
Hi Vikram, That is probably the fastest solution. But could you explain me what actually the tstngwtrs-GroupCurves does?
Sure I will. Lemme figure out how to mark as solved first though
(click on the three points that can be seen at the back of each post, you will find a button with this tooltip: “This reply solves the problem”)
Probably because it doesn’t use any geometry intersection (which can be really heavy) to do it’s job.
If you have a list of shuffled curves, it groups together curves that form loops (open or closed)
The illustration at the link I’ve provided above should give you a fair idea of what it does.
I`ve tried to use your solution , but get an errors in the script, dynamo 1.3.3, revit19
Screenshot is below
Any thought what is wrong out here?
PolyCurve.ByJoinedCurves error is: Warning: PolyCurve.ByJoinedCurves operation failed.
PolyCurves may not be branching
Surface.ByPatch error is: Warning: Surface.ByPatch operation failed.
Unable to patch a single, no-closed curve
Thanks in advance
Seems like you have intersecting/overlapping curves. Grouping of curves only helps group curves that are a part of detached chain of curves.