How to trim a trimmed surface using a rectangle

I have a trimmed surface (see below) and I’d like to eliminate any part of it that’s outside the green rectangle. Region Difference and Trim with Region are both wrong for the job it seems.

How should I do this? Feels like the answer should be obvious, but I’ve spent nontrivial time googling and experimenting about without results.

Trim Surface Question for Forum Aug (69.2 KB)

Hi @Raam,

Rather than using the Trim component, use a C# component that calls Brep.Split.


You’ll need to figure out what to keep and what to toss.

Split Surface Question for Forum Aug (57.0 KB)

– Dale

You can also do this with the native grasshopper Split Brep component but it’s considerably slower than your script (~2.6 sec. vs. ~1 sec.).

Split Brep Question for Forum Aug (61.1 KB)

It seems that some of the native grasshopper components that do boolean or intersection operations are slower than doing the same operations with scripting. Perhaps these components could use a tune-up?