Dear all,
I’m encountering an issue with a Grasshopper script I’m working on. The goal is to generate simple windows (srf) on a façade based on an input geometry (extrusion or closed polysrf). The windows should be generated per storey.
While the script works fine with basic geometries, it fails as soon as the input geometry becomes more complex. For example, in the two attached cases (see grasshopper script), the Isotrim component doesn’t behave as expected or wished: the resulting window surfaces either overlap or extend beyond the actual input geometry.
I’d greatly appreciate any advice or help in resolving this issue!
Thanks in advance and best regards,
Marc
Question_Facade_Isotrim_v0.1.gh (32.6 KB)
Isotrim untrims its input faces 
I see other issues in this code, like connecting one of the “NOT WORKING” breps to Contour instead of the output from Stream Filter?
Hi Joseph!
do you have a suggestion how I could solve the aforementioned issue?
Best
Marc
Avoid passing trimmed surfaces to Isotrim ?
Split the unflattened list of surfaces from Split Brep Multiple?
You need to break down your surfaces from L shapes and what-not in to rectangles. Isotrim is working on the larger bounding rectangle of these surfaces, i.e. untrims them, as Joseph says.
1 Like
Thanks! I’m looking for a solution - ideally without relying on external plugins like Pufferfish, as previously suggested (even though it works!).
However, when I try to apply your solution, I get an error (“splitting returned no results”). Could you possibly share a screenshot of your full setup? That would help me follow your approach more accurately.
PS: @Jospeh_Oster: I simply overlooked the misconnection with the Stream Filter. 
I’m not sure which of the changes I made are necessary but suspect sFace (yellow group) here is one of them.
Facade_Isotrim_2025May25a.gh (43.4 KB)
It is one line of C# I got on this forum years ago:
private void RunScript(Brep B, ref object sB)
{
B.Faces.ShrinkFaces();
sB = B;
}
Unfortunately, the one that was working is now broken
Haven’t delved into why yet. 
Grafting the output of sFace fixed things but had to add a filter (purple group) for surfaces that are are too small in Z due to contour alignment. (to fix an anomaly in the “working” brep)
Facade_Isotrim_2025May25b.gh (43.5 KB)
Question_2_Facade_Isotrim_v0.1.gh (11.3 KB)
Thanks this helped! Last question in this context (isotrim again): how can I manage to get the isotrim surfaces only for the previously referenced srf area (currently its using the boundary)…?
Please don’t ask me to read multiple copies of your code, especially when you have ignored my previous efforts. Is there a problem with the code I posted?
P.S. If I understand your “Question 2” correctly, I this what you want?
Facade_Isotrim_2025May25c.gh (13.0 KB)
1 Like
Exactly, that’s it. Thanks again for your efforts and proposed solutions. They work and solve the problem!
The password-protected cluster ExtVert has bothered me because I can’t inspect it. This is not a functional change (hopefully) and should work exactly the same way.
Facade_Isotrim_2025May25bb.gh (39.6 KB)
The DProd (Dot Product) output has this expression: round(abs(x))
2 Likes
Oops. I almost forgot to post this. Too often we write GH code using flatten that doesn’t work well on multiple branches. I was surprised that at first glance, this code seems to handle them well.
Still, I went through the code again, paying more attention to the data trees with all three breps at once. Removed several flattens so in theory, this should work with any number of buildings.
Facade_Isotrim_2025May25d.gh (40.9 KB)
1 Like
Indeed, that makes it cleaner - thanks again, appreciate it!
I just had another look at the proposed solution - is there an option to use the snippet in a way that the surfaces are culled at exactly the corner (crv outlines)? Currently its overlapping and not “exactly” fitting to the inital geometry.
Things fall apart when the building heights are not a multiple of the floor heights:
What “snippet”? P.S. Oh, I think I understand what you’re saying. Yes, the “snippet” of GH in that purple group is too simple. You must understand it 
That’s why I added the purple group. Does it need tweaking?
The “snippet” > I am referring to the floor slabs not the facade - maybe I am missing something, but I added the aforementioned purple grasshopper script and with that its not cutting it as needed. Any idea how to modify it?