New feature: ProfileEdges - Cut open edges [Merged]

Here's the place for discussion related to CAM/CNC and the development of the Path module.
Russ4262
Posts: 376
Joined: Sat Jun 30, 2018 3:22 pm

New feature: ProfileEdges - Cut open edges [Merged]

Postby Russ4262 » Sun Feb 16, 2020 9:53 pm

Afternoon FC users,
A long awaited feature might be coming to FreeCAD in the near future: Profile open edges. The new PR, that I plan on submitting soon, contains no new properties or user inputs, but is an upgrade from the current version. The upgraded version will work on open edges, with a few restrictions. Here is some more information.

Current conditions and information:
  • Admittedly, this new feature, as with most I present, is experimental to a certain degree. It lacks extensive testing.
  • Open edges, exterior or interior, can now be used to generate paths.
  • The new feature requires the parent face to be vertically oriented (standing). Curved vertical face edges are okay.
  • The user must select upper (top) edges. The current implementation needs the Z-height value of the "edge face" to function correctly. Selecting the bottom edge will return an error and no path. Bottom-edge-selection might be available in future versions.
  • The beginning and end of generated paths may not be exactly where the user wants, but the model geometry is respected. The algorithm needs further development to better refine the ends of the path. I think I will have to discretize the original edge and use the first/last segments to calculate a perpendicular line to refine the endpoints for the path. Then I will have to discretize the ends of the path wire generated and trim/extend segments to arrive at the happy ending point. This will require more work, but I think would be a desirable improvement.
  • Cut direction seems sporadically determined by Path.fromShapes(), but the `Direction` property will still switch the direction of cut. The `CW` and `CCW` direction labels might not align with the actual direction, but the direction of cut will toggle to the opposite direction when the property value is changed. Additional algorithm modification is necessary to enforce fidelity to the labels.
  • I have not done any testing with sketch edges, or similar wire objects. I have only tested solids. I would like to extend functionality to sketches and wires, but I don't have a time frame or priority designation for such an improvement.
  • I am confident that the algorithm can be adapted to PocketShape to allow for open pockets to be cleared. I actually saw this happen during intermediate stages of development for this particular algorithm, but I passed over it because "the mission at hand was priority." Anyhow, I can go back and revisit that feature later if need be.
See the images below. I'm also attaching the model file.

I have a few open PRs at the moment. This one affects the PathOpArea module. This new PR will be based upon the existing FinalDepths fix in the PR list. This existing PR needs to be committed before the new PR.

I'll will update this post with the new PR info when I get around to that.

Here's to a more capable PathWB! … and grading papers. :) #ATeachersLife

Russ
Attachments
ProfileEdges_Open_Edges-1.png
ProfileEdges_Open_Edges-1.png (171.21 KiB) Viewed 522 times
ProfileEdges_Open_Edges-2.png
ProfileEdges_Open_Edges-2.png (155.97 KiB) Viewed 522 times
_ProfileEdges_test.FCStd
model file used for ProfileEdges open edges feature
(82.27 KiB) Downloaded 3 times
Last edited by Russ4262 on Thu Feb 27, 2020 3:20 pm, edited 1 time in total.
chrisb
Posts: 22579
Joined: Tue Mar 17, 2015 9:14 am

Re: New feature: ProfileEdges - Cut open edges

Postby chrisb » Sun Feb 16, 2020 10:07 pm

Great again! From what I have seen here, many Path'ers have waited for this.
User avatar
Wsk8
Posts: 88
Joined: Fri Dec 07, 2018 6:24 pm

Re: New feature: ProfileEdges - Cut open edges

Postby Wsk8 » Sun Feb 16, 2020 10:12 pm

Looks really impressive!!
Can't wait till its release.

BR
User avatar
dubstar-04
Posts: 456
Joined: Mon Mar 04, 2013 8:41 pm
Location: Manchester, UK
Contact:

Re: New feature: ProfileEdges - Cut open edges

Postby dubstar-04 » Mon Feb 17, 2020 6:31 am

Nice work Russ!
RatonLaveur
Posts: 471
Joined: Wed Mar 27, 2019 10:45 am

Re: New feature: ProfileEdges - Cut open edges

Postby RatonLaveur » Mon Feb 17, 2020 9:20 am

That man is a machine!
Really well done.

There was an open discussion on this very topic involving generating facing operations for vertical faces ( i do not recommend switching edges to faces!) And sliptonic had provided a compelling case against it as well as a very simple yet tricky test model.

Edit: bingo found it! https://forum.freecadweb.org/viewtopic.php?f=15&t=41469

Since the last comment is by Russ maybe my attempt to link these discussions is moot...
memfis
Posts: 168
Joined: Tue Nov 15, 2016 7:58 pm

Re: New feature: ProfileEdges - Cut open edges

Postby memfis » Mon Feb 17, 2020 10:31 am

Every day I look that new from Patch entered the appimage

https://github.com/FreeCAD/FreeCAD/commits/master

and neither this nor 3d progress there - I do not see.
And I would like to, because of the path created by the program to the edge then have to cut off the extra in the editor.
Russ4262
Posts: 376
Joined: Sat Jun 30, 2018 3:22 pm

Re: New feature: ProfileEdges - Cut open edges

Postby Russ4262 » Tue Feb 18, 2020 5:47 am

No worries.

We are still searching for, and fixing bugs. We want to release the most dependable, stable, capable, and productive version reasonably possible.

Thanks for the show of support!

Russ
PedjaS
Posts: 16
Joined: Sat Jan 18, 2020 6:35 pm

Re: New feature: ProfileEdges - Cut open edges

Postby PedjaS » Tue Feb 18, 2020 8:16 am

This is great news! Really needed function.
User avatar
dubstar-04
Posts: 456
Joined: Mon Mar 04, 2013 8:41 pm
Location: Manchester, UK
Contact:

Re: New feature: ProfileEdges - Cut open edges

Postby dubstar-04 » Thu Feb 20, 2020 9:42 am

Hi Russ,

Is there anything I can do to help with this?

Thanks,

Dan
Russ4262
Posts: 376
Joined: Sat Jun 30, 2018 3:22 pm

Re: New feature: ProfileEdges - Cut open edges

Postby Russ4262 » Thu Feb 20, 2020 12:27 pm

Morning, Sir.
Frankly, I'm not sure. I don't have much experience with real collaboration on these projects. Feel free to submit your ideas for tackling the open edges, or even a PR for such a feature. As a novice, I yield to you all who really do know what your doing. At the moment. I am more like Mr. Edison testing iteration 116 of the light bulb, not knowing if I will make it to 1000 plus attempts before success.

Currently I'm reworking the algorithm after some more intensive testing revealed grand failures.

I appreciate the offer. I'm reconstructing the analysis strategy in an effort it better handle more complex open-edge scenarios.

I will gladly accept help. I just don't know what that is on this one. It's like my wife asking me what I'm making, and my response is, "I'm not sure" bacause I've never seen one and I'm not certain what it should look like. Lol

Sincerely,
Russell
dubstar-04 wrote:
Thu Feb 20, 2020 9:42 am
Hi Russ,

Is there anything I can do to help with this?

Thanks,

Dan