Added some comments about things to be fixed in the future

This commit is contained in:
jrheinlaender 2013-08-26 14:38:16 +02:00 committed by Stefan Tröger
parent 010761d162
commit 9dba4c01e2
2 changed files with 10 additions and 4 deletions

View File

@ -153,8 +153,12 @@ App::DocumentObjectExecReturn *Pocket::execute(void)
}
getUpToFace(upToFace, base, supportface, sketchshape, method, dir, Offset.getValue());
// Special treatment because often the created stand-alone prism is invalid (empty) because
// BRepFeat_MakePrism(..., 2, 1) is buggy
// BRepFeat_MakePrism(..., 2, 1) in combination with PerForm(upToFace) is buggy when the
// prism that is being created is contained completely inside the base solid
// In this case the resulting shape is empty. This is not a problem for the Pad or Pocket itself
// but it leads to an invalid SubShape
// The bug only occurs when the upToFace is limited (by a wire), not for unlimited upToFace. But
// other problems occur with unlimited concave upToFace so it is not an option to always unlimit upToFace
// Check supportface for limits, otherwise Perform() throws an exception
TopExp_Explorer Ex(supportface,TopAbs_WIRE);
if (!Ex.More())

View File

@ -628,8 +628,10 @@ void SketchBased::generatePrism(TopoDS_Shape& prism,
const bool SketchBased::checkWireInsideFace(const TopoDS_Wire& wire, const TopoDS_Face& face,
const gp_Dir& dir) {
// Project wire onto the face (face, not surface! So limits of face apply)
// FIXME: For a user-selected upToFace, sometimes this returns a non-closed wire for no apparent reason
// Check again after introduction of "robust" reference for upToFace
// FIXME: The results of BRepProj_Projection do not seem to be very stable. Sometimes they return no result
// even in the simplest projection case.
// FIXME: Checking for Closed() is wrong because this has nothing to do with the wire itself being closed
// But ShapeAnalysis_Wire::CheckClosed() doesn't give correct results either.
BRepProj_Projection proj(wire, face, dir);
return (proj.More() && proj.Current().Closed());
}