Forum archiveIssue archiveOther usage issues

Archived discussion

BRepTools_Reshape: problem of location of the replaced shapes.

Other usage issuesMon, 10/03/2005 - 12:261 reply

Browse this forum
QuestionAuthor

Hi, I hope someone can help me.
I'm trying to replace some faces of a TopoDS_Shape by others.
I use the method BRepTools::Reshape.
It works, but I have a problem with the location of the new faces.
It seems that the BRepTools::ReShape don't consider the location of the new face. The location of the new face doesn't appear in the replaced face.
Do you know how to take into account the location?

Here is my code:
TopoDS_Shape shape = .....
TopoDS_Face oldFace = ..... // a face of the shape
TopoDS_Face newFace = ..... // a new face
newFace->Location(oldFace->Location());

BRepTools_ReShape change;
change.ModeConsiderLocation() = true;
change.Replace( *(*it)->face[i]->face,*face2, true);
shape = change.Apply(shape, TopAbs_FACE);

If someone has an idea, reply me...
Thanks
Marie

Discussion

1 archived reply

Posts are displayed in their archived order.

01Commenter-1

HI Marie!
I have small doubt in ur question itself. How did u identify the face? before u change them? In case if u have box(100,100,100), how do u first identify the left and right faces?

Is it possible to store face ids in array? and also Is it possible to access the faces by their ids?

If possible pls give me an example code, sorry i am new to OC.