For all issues regarding the Forums use, please, refer to the Forum Rules.

Our Solutions

Need professional assistance?
Consider our:

Support Offerings


Need to speed up your development?
Have a look at our:

Samples & Tools


Need some functionality extending standard OCCT capabilities?
Check out our:

Adv. Components

Related pages

Bounded HalfSpace Solid

Thomas Krijnen's picture

Hi all,

I am using Open Cascade for an open source IFC geometry converter. IFC is a format very similar to STEP so with the use of Open Cascade most of the geometry interpretation is rather easy.

However, there is one type of geometry I can't seem to implement elegantly: a halfspace solid bounded by a polygonal boundary:

There does not seem to be a direct counterpart in the Open Cascade classes? The way I implemented it now is by simply extruding the boundary, but this leads to all sorts of problems.

Does anybody have an idea how to construct this polygonal bounded halfspace?

Thanks in advance.

Kind regards,

Thomas Krijnen's picture

Hi all,

I just stumbled on a way of creating an infinite solid, by means of the BRepPrimAPI_MakePrism which has a constructor to create an infinite prism from a face. I ended up implementing a more elaborate method, but for reference here is code to produce a polygonal bounded halfspace from a wire and a plane:


TopoDS_Wire the_boundary;
gp_Pln the_plane;
// ...
TopoDS_Shape prism = BRepPrimAPI_MakePrism(BRepBuilderAPI_MakeFace(the_boundary),gp_Vec(0,0,1),1,0,1);
gp_Pnt pnt = pln.Location().Translated(pln.Axis().Direction())
TopoDS_Shape halfspace = BRepPrimAPI_MakeHalfSpace(BRepBuilderAPI_MakeFace(pln),pnt).Solid();
TopoDS_Shape bounded_halfspace = BRepAlgoAPI_Common(prism,halfspace);

Kind regards,

Contact us

Attention: DO NOT use this form for all kind of request for the removal of your personal data. Please follow this link for such cases.