In versions prior to 1.0 there was never the requirement that the shape of a FeatureBase must contain a solid. This has changed with ea0a7b0679 for no obvious reason. This requirement should be dropped again.
In versions prior to 1.0 the method Feature::getBaseShape() was used within the Pad feature to check if the base feature has a solid. This method throws an exception if the shape doesn't have a solid.
Since version 1.0 the new method Feature::getBaseTopoShape() is used. As parameter a boolean is passed to either throw an exception or silently return a null shape. The implementation of this function is inconsistent:
If the parameter is false it throws an exception if the base feature's shape has no solid but if the parameter is true it doesn't check if the shape has a solid and returns it as is.
This leads to incorrect behaviour in the calling instance where the shape of the base feature is tried to be fused with the padded shape. This operation will fail if the shape of the base feature has no solid.
This fixes https://github.com/FreeCAD/FreeCAD/issues/23348
The default tolerance to check for a planar B-spline surface is 1.0e-7 which might be too strict in some cases.
Therefore the tolerance is increased to 2.0e-7.
This fixes issue 21242
This unifies deletion behavior for all PartDesign features ensuring that
sketches that were used to create these features show after deletion and
that the tip is properly transfered.
* Enabled Draft to accept sketch as neutral plane
* Resolving the last review
* Fix: tested the Feature with test file
* Fix: error with sketch pointer
* PartDesign: Simplify selection implementation
---------
Co-authored-by: Ziad <ziad.ashraf.cs@gmail.com>
Fixes issue 19183 also reported in the forum:
https://forum.freecad.org/viewtopic.php?p=806495https://forum.freecad.org/viewtopic.php?t=88234
The actual reason for the failure is that the new code uses
FaceMakerBullseye method which expects coplanar wires.
The code was using FaceMakerCheese previously which changed
in LinkStage with their commit 93ce3edfe7ff
("PD: use FaceMakerBullseye for feature Loft")
and was imported here with TNP mitigations.
As changing it back would cause different regressions, lets
try different facemakers until one succeeds.
Fixes: 301194a69682 ("Toponaming/Part: Fix all getBaseTopoShape calls...")
Co-authored-by: Benjamin Nauck <benjamin@nauck.se>
Co-authored-by: Werner Mayer <wmayer@freecad.org>
* PartDesign: Hole: Find direction of cylindrical face in Hole::execute instead of FeatureSketchBased::getProfileNormal
* PartDesign: Minor cleanups in guessNormalDirection
---------
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
The passed DocumentObject pointer can be null which is nowhere checked.
This fixes issue 19545
Fixes: 256ad7a01a ("PartDesign: Loft Intelligence - Select the whole sketch if the selected shape is ...")