why does GeomFill class break the creation of surface into three procedures?

eue

Active CAD practitioner
To make a Geom_XXSurface using GeomFill_XXX, you need the surface generator, the approximate calculator, and finally the Geom_XXSurface created with calculated parameters.
What is the decision and consideration behind breaking surface creation into these three procedures? It makes the program more complicated and difficult to code so I am guessing a reason behind it.
 

Quaoar

Administrator
Staff member
Are you referring to some specific tool from the GeomFill package? I remember using GeomFill_ConstrainedFilling and GeomFill_Pipe without a need to define any extra generators/calculators/etc; it was as simple as calling their Perform() methods. Then, some more sophisticated procedures might be exposed by OpenCascade for more advanced use, e.g., if you need variable-diameter piping or advanced skinning techniques. But in traditional modeling scenarios, such as lofting, filleting, piping, the API provided by OpenCascade out of the box does not seem to be overly verbose, at least, in my opinion.
 

eue

Active CAD practitioner
Are you referring to some specific tool from the GeomFill package? I remember using GeomFill_ConstrainedFilling and GeomFill_Pipe without a need to define any extra generators/calculators/etc; it was as simple as calling their Perform() methods. Then, some more sophisticated procedures might be exposed by OpenCascade for more advanced use, e.g., if you need variable-diameter piping or advanced skinning techniques. But in traditional modeling scenarios, such as lofting, filleting, piping, the API provided by OpenCascade out of the box does not seem to be overly verbose, at least, in my opinion.
Thanks for the reply.
Yes I am referring to the GeomFill package. For example in order to create the BSplineSurface you have to use a generator and GeomFill objects like Line and AppSurf to create the Geom_BSplineSurface. This seems to complicate the creation procedure, so I am wandering what is the use of generator and Geom objects here and why is the code designed this way?
Or maybe this is all a obsolete design?
1680745433040.png
BTW, could you also offer a code example of the simplier way you mentioned.
 
Last edited:

blobfish

CAD community veteran
I agree that is pretty verbose for what you are trying to do. I started looking around and didn't find anything. Checked in on romans blog and he has pretty much the same procedure as you. I guess that is it for doing 'through curves' at the geometry level. Things are better at the topology level with BRepOffsetAPI_ThruSections, but that probably doesn't help you at all. Let us know if you find a better way.
 

xuzhongxing

Looking around for some CAD
This piece of code is doing what is called multisection surface creation in typical CAD programs like catia.

The real approximation work is done GeomFill_AppSurf class.

The first part is adding multiple section curves that are expected to be interpolated by the approximated surface.

The final part is getting the resulting b-spline surface from the parameters computed by GeomFill_AppSurf.
 
Top