mirror of
https://github.com/NGSolve/netgen.git
synced 2025-01-23 19:30:33 +05:00
Fix Workplane.Offset for straight lines
This commit is contained in:
parent
61366f4c8e
commit
6533663b7f
@ -633,8 +633,12 @@ public:
|
|||||||
{
|
{
|
||||||
TopoDS_Wire wire = wires.back();
|
TopoDS_Wire wire = wires.back();
|
||||||
wires.pop_back();
|
wires.pop_back();
|
||||||
BRepOffsetAPI_MakeOffset builder;
|
|
||||||
builder.AddWire(wire);
|
// handle wires containing a single edge correctly, see
|
||||||
|
// https://dev.opencascade.org/content/brepoffsetapimakeoffset-open-topodswire
|
||||||
|
BRepBuilderAPI_MakeFace makeFace{gp_Pln{axes}};
|
||||||
|
makeFace.Add(wire);
|
||||||
|
BRepOffsetAPI_MakeOffset builder(makeFace.Face());
|
||||||
builder.Perform(d);
|
builder.Perform(d);
|
||||||
auto shape = builder.Shape();
|
auto shape = builder.Shape();
|
||||||
wires.push_back (TopoDS::Wire(shape.Reversed()));
|
wires.push_back (TopoDS::Wire(shape.Reversed()));
|
||||||
|
Loading…
Reference in New Issue
Block a user