Millface filling in gaps inappropriately

Here's the place for discussion related to CAM/CNC and the development of the Path module.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
gringusboii123421
Posts: 13
Joined: Mon Sep 12, 2022 12:44 am

Millface filling in gaps inappropriately

Post by gringusboii123421 »

I have a design for the letters AR, and am hoping to have just the lettering cut from the material, however when I use a millface operation, it fills in the "holes" in the letters as well, even though the geometry I'm using should exclude those. It seems like it should be an easy fix but I have been trying various different methods without success. Thanks in advance!
Attachments
Incorrect AR 1.FCStd
(102.61 KiB) Downloaded 21 times
Russ4262
Posts: 941
Joined: Sat Jun 30, 2018 3:22 pm
Location: Oklahoma
Contact:

Re: Millface filling in gaps inappropriately

Post by Russ4262 »

gringusboii123421 wrote: Sat Jun 03, 2023 7:44 pm ... It seems like it should be an easy fix but I have been trying various different methods without success. ...
Evening.
Yes, it should be easy, but will not be due to some bugs. I can confirm the errors with the file you provided. I did have to apply the Job Fixer script to upgrade your file to the new code structure for current weekly builds.

I found three bugs, two I have fixed on my end that will allow the two letters to be milled using independent operations. The third bug exists, but I do not know the origin, so cannot attempt to correct it. This particular third bug has to do with the two faces being processed within a single operation. For some reason the geometric envelopes are not being correctly created internally that are used to build the target removal shape.

Out of curiosity, I checked your file against the Pocket Shape operation, and it failed there as well. I found the bug in that op and corrected that on my end with good results.

I will need to do more testing with my preliminary fixes to confirm the changes truly address the issue properly with no negative repercussions to current features.

May I suggest you consider scanning the GitHub issues for FreeCAD Path WB to identify whether or not this MillFace issue has officially been reported there. If not, my suggestion is to create an official issue. The FreeCAD contributing policy provides guidelines.

Thank you for reporting this issue.

Russell

Code: Select all

OS: Windows 10 build 19045
Word size of FreeCAD: 64-bit
Version: 0.21.0.33321 (Git)
Build type: Release
Branch: master
Hash: 1d61ed187c9633702818c6cc5d7a1f07dd052ca8
Python 3.10.11, Qt 5.15.8, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.3
Locale: English/United States (en_US)
Installed mods: 
  * FC_SU
  * freecad.gears 1.0.0
  * PathExp
  * Z_MacroStartup
Attachments
Snip macro screenshot-4a29c9.png
Snip macro screenshot-4a29c9.png (113.68 KiB) Viewed 1623 times
gringusboii123421
Posts: 13
Joined: Mon Sep 12, 2022 12:44 am

Re: Millface filling in gaps inappropriately

Post by gringusboii123421 »

Russ4262 wrote: Sun Jun 04, 2023 2:13 am
gringusboii123421 wrote: Sat Jun 03, 2023 7:44 pm ... It seems like it should be an easy fix but I have been trying various different methods without success. ...
Evening.
Yes, it should be easy, but will not be due to some bugs. I can confirm the errors with the file you provided. I did have to apply the Job Fixer script to upgrade your file to the new code structure for current weekly builds.

I found three bugs, two I have fixed on my end that will allow the two letters to be milled using independent operations. The third bug exists, but I do not know the origin, so cannot attempt to correct it. This particular third bug has to do with the two faces being processed within a single operation. For some reason the geometric envelopes are not being correctly created internally that are used to build the target removal shape.

Out of curiosity, I checked your file against the Pocket Shape operation, and it failed there as well. I found the bug in that op and corrected that on my end with good results.

I will need to do more testing with my preliminary fixes to confirm the changes truly address the issue properly with no negative repercussions to current features.

May I suggest you consider scanning the GitHub issues for FreeCAD Path WB to identify whether or not this MillFace issue has officially been reported there. If not, my suggestion is to create an official issue. The FreeCAD contributing policy provides guidelines.

Thank you for reporting this issue.

Russell

Code: Select all

OS: Windows 10 build 19045
Word size of FreeCAD: 64-bit
Version: 0.21.0.33321 (Git)
Build type: Release
Branch: master
Hash: 1d61ed187c9633702818c6cc5d7a1f07dd052ca8
Python 3.10.11, Qt 5.15.8, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.3
Locale: English/United States (en_US)
Installed mods: 
  * FC_SU
  * freecad.gears 1.0.0
  * PathExp
  * Z_MacroStartup
Thank you.
If you have the FreeCAD file to upload so I could have a look I would really appreciate it. Thank you so much for looking into this!
Russ4262
Posts: 941
Joined: Sat Jun 30, 2018 3:22 pm
Location: Oklahoma
Contact:

Re: Millface filling in gaps inappropriately

Post by Russ4262 »

gringusboii123421 wrote: Sun Jun 04, 2023 3:05 am ... If you have the FreeCAD file to upload so I could have a look I would really appreciate it. Thank you so much for looking into this!
Evening.
I do, but my FC version is of the new code structure, and your version is the older code version. So, your version will not read my version correctly. Apart from that, my file is nothing special, as I applied some fixes to my FC code to achieve the paths shown previously.

Fear not, I have a fix for you. Attached is a macro that will convert your "Cut002" clone object to a usable type for the Pocket_Shape operation.

- Download the attached "_ConvertFace.FCMacro" file, and place it in your macro folder.
- Start FreeCAD, and open your source file - the one shared in the OP.
- Select the "Cut002" labeled object in the object tree.
- Run the macro, and it will create a new object in the file with the same physical shape, labeled the same with a "Converted-" prefix.
- Edit your Job object, and add the new "Converted-..." object as a base model to the Job.
- Save the Job.
- Ensure the "Cut002" object and respective "Model-Cut002" objects are hidden, so the new "Converted-..." or "Model-Converted-..." objects are visible.
- Select one or both faces of either the "Converted-..." or "Model-Converted-..." objects, and create a Pocket_Shape operation.

Hope this helps,
Cheers.

Russell
Attachments
_ConvertFace.FCMacro
Macro to convert incompatible horizontally planar faces of selected object.
(3.09 KiB) Downloaded 21 times
gringusboii123421
Posts: 13
Joined: Mon Sep 12, 2022 12:44 am

Re: Millface filling in gaps inappropriately

Post by gringusboii123421 »

EDIT: I tried your above solution, and it worked! Thanks a million. I'll leave my post below and files in case it could be helpful in troubleshooting the bugs you mentioned. Have a nice day


"I tried splitting the letters into two parts, so that there wouldn't be a "hole" for the software to even recognize, but was met with the same problem and/or errors. See file attached.

To the poster above, if you have the file from the screenshot you posted I would really appreciate having it! Thanks."
Attachments
Corrected AR individual.FCStd
(163.48 KiB) Downloaded 16 times
Post Reply