How to use BRepFeat_Gluer

Hey guys!

I am trying to glue two faces together, but I was not a able to get a result (exception raised).

TopoDS_Face face1 = TopoDS::Face(shape1);
TopoDS_Face face2 = TopoDS::Face(shape2);
BRepFeat_Gluer aGluer(shape1,shape2);
aGluer.Bind(face1,face2);
LocOpe_FindEdges fined(face1,face2);
for(fined.InitIterator(); fined.More(); fined.Next())
{
aGluer.Bind(fined.EdgeFrom(),fined.EdgeTo());
}
aGluer.Build();

What is wrong with the code above?

Alex

Adorjáni Alpár's picture

Hi,

I have seen in the demo Application the example. I understand it so that the Bind function gets only the common elements to unite them.
So when here we want to glue two faces, then the gluer gets those faces but the Binder then the common edges to remove them.
So first you have to search for the neighbour, common edges.

When it would be a solid glueing, only then must the bind to remove the common faces.

Aak