Open-Cascade-SAS/OCCT

Fillet can not round a face

Opened this issue · 7 comments

Category

Modeling

Severity

Major

Description

I know this bug is in the original tracker 25478

When modeling existing parts, often fillets touch each other directly, meaning that there is no linear segment remaining, but they just have tangent (C1) point at which they touch.When trying to apply those fillets OCCT thrown a standard_error with "BRep_API: command not done"

but it has been 10 years since it was reported and there is no sign of any attention or progress done on this. Please someone needs to look into it since it feels like the most important problem now in FreeCAD

Expected Behavior

if the fillet radius is big enough that there are no linear faces remaining, it should round the face.

Actual Behavior

The fillet will work as long as the radius is small enough to keep some face remaining. if it is big it will not work.

Sample Code or DRAW Tcl Script

bugs modalg_7 bug25478_1, bug25478_2

pload MODELING
box Box 10 10 10
explode Box E
blend Fillet Box 5 Box_1 5 Box_3
#tolerance ang : 0.01
#tolerance 3d : 0.0001
#tolerance 2d : 1.0000000000000001e-05
#fleche : 0.001
#tolblend 0.01 0.0001 1.0000000000000001e-05 0.001
#
#the variable Fillet is left unset
#concave example
#generated by FreeCAD 0.15.4183 +7 (Git)
pload MODELING
box Box001 10 10 10
box Box002 10 10 12
ttranslate Box002 5 5 -1
bcut Cut Box001 Box002
explode Cut E
blend Fillet002 Cut 2.5 Cut_13 2.5 Cut_17 2.5 Cut_18
donly Fillet002

Operating System

Linux

Compiler

GCC

Bitness

64-bit

OCCT Version

latest

What do you mean by "round the face"?

  • Use the requested radius and leave sharp corners?

  • Change the radius to fit?

  • Just create some artibrary shape that looks "round"?

It may be easier to explain visually:

I have the following simple shape with height 10 mm
image

now I want to apply a fillet on all sides that is 4 mm, will work without any problem
image

because there is still a face connecting the 2 red fillets there is no problem so far.

now if I want to make the fillet 5mm that means they will touch and the grey face between them will have 0 mm length and will refuse to do the fillet with the error:
BRep_API: command not done

I hope this makes the issue a bit clearer, this is also in chamfer not just a fillet problem, let me know if you need any information or if I can be of any help.

I understand the issue. I have seen it many times.

The question is what should happen when the fillet cannot be completed as specified.

I don't know if it will be easy but the logic of this should be: If the fillet causes a face dimension to be 0 then delete that face.

What should happen in my example is the gray face that was 2 mm and became 0 mm due to fillets should be deleted and the upper and bottom fillets should connect as tangents. Does that make sense? I don't know if there is an easier way to make this work but that's how it is in other commercial CAD software.

OK, now they are tangent at the former face along the edge. What happens at the other ends? Sharp break in the curve? Changed radius of the fillet so that the other ends can be tangent to those faces?

In my example both the top and bottom fillets have the same radius so both of them would be tangent without changing any radius.

But if I understand you correctly you are asking what if they cannot be tangent due to radius difference or other constraints, from my experience in other CAD software, you should never change the other fillet's radius, keep the sharp corners and let the dimension changes in the user's control.

I don't know if this would help in the implementation, but I believe the behavior used by commercial CAD software is equivalent to performing the fillet on each edge loop separately and then taking the intersection. So in this example we would duplicate the part, perform the top fillet on one copy, perform the bottom fillet on the other copy, and then do a boolean intersection to get the final result. As long as boolean intersections don't have some other issue, this should work for both over-fillet and critical-fillet (as is used in this issue), so two birds with one stone.