Combining/Rebuilding Brep

Hi team,

I have two polysurfaces, made of 3 (left) & 2 (right) breps, that I want to blend using C# script and the Brep.CreateBlendSurface (sourced from the forum). Effectively, I am trying to recreate the ‘chain edges’ command in Blendsrf on Rhino.

My issue is that when I call the edge index, it only grabs the individual Brep edge and not the polysurface edge. I also can’t seem to get multiple inputs for the Edge index without it running as different operations. See below:

I was thinking that the solution could come from either:

  1. rebuilding the breps of each poly surface to create one brep (2 total)
  2. Including multiple edges in the index

Maybe there’s a better solution that I’m not even considering!

Thanks in advance for the assistance - I freaking love these forums.

Grasshopper file:
Merge (4.3 MB)

Merge Breps Edited V0 (4.1 MB)
This definition makes the Breps into surfaces.
Note that BlendSurface in GH is not the same thing as Rhino’s.

Hi, is this a unique operation? Don’t do such things in Grasshopper. There is absolutely no benefit in it, unless you are planing to repeat this process in a very similar way for more than 10 times.
I think the problem is a different here. The iso-curves indicate a very unclean modelling process.

If this was modelled by you, than it means you need to learn a lot about surface modelling first. Rhino offers lot of tutorials about surface modelling. There are plenty of online tutorials free to watch.

Also, always assume that its harder to model surface models in Grasshopper, so you need to find the ideal solution in a manual process, before even considering automating it. Then understand that GH lacks most of the advanced surface modelling features of Rhino. Think about how to workaround Grasshopper limitations if you have a proper Rhino model. The truth is, that with intermediate modelling skills, you should be a able to properly blend a clean version of this shape in a few minutes.

Hi Tom,

This is part of a very large GH script that aims to model a tailored shoe lasts from 3D scan data - hence the ‘unclean modelling’.

The script is definitely intended for repeated use and hence the necessity to use GH and not model in Rhino

Thank you very much, I appreciate the script. I’ll give it a go, understand the operations and get back to you. Cheers Quan!

1 Like

Scan or not, but this surface layout is problematic. You have too many cvs. And the iso curve flow is very bad, especially for blending. If you switch to a better surface layout, blending even with GH Blendsurface will yield a much better result. See my quick sketch:

Other than that. Modelling a shoe exclusively in Grasshopper is difficult, because as I said, you are lacking surface tools. So in any case, you will have a hard time. All you can do about it, is to create conditions which allow you to simplify as much as possible and if required minimise the manual post-processing.

Edit: For perfect blend conditions your surfaces should match in position in its theory:

Thanks mate, I’ll be sure to reach out if we redo this area of the script :slight_smile: