libarea, used in Path Workbench

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!
danielfalck
Posts: 395
Joined: Fri Oct 07, 2011 8:58 pm
Location: Beaverton,Oregon, USA
Contact:

libarea, used in Path Workbench

Post by danielfalck »

This might be a good place to discuss 'libarea' the pocketing/profile generating library that we have adapted from HeeksCNC to use with the Path workbench. So far it is only used for one version of Profiling in Path but I intend on using it with pocketing too. In my experience with HeeksCNC, it does pocketing very well.

I have adapted it to the Path workbench here for testing:

https://github.com/danielfalck/FreeCAD/tree/path_area

We can merge it into the master branch, after some testing.
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: libarea, used in Path Workbench

Post by sliptonic »

Nice work Dan!

For those that are unfamiliar with libarea, HeeksCNC also uses it to do 3D surfacing operations. This is just a fancy pocket operation where the Z depth of the cutter is controlled by a solid underneath the bounding sketch.
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: libarea, used in Path Workbench

Post by triplus »

As for the compiling (and PPA) documentation needs to be updated for new dependency. For Ubuntu:

Code: Select all

libboost-python-dev
Beyond that it compiles fine on Ubuntu. There is something i would like to see changed if possible. Running cmake infroms the user libarea will be installed in /usr/local/lib folder but what would be nice is to be able to run FreeCAD after compiling it and to have fully functional Path WB without actually making the install. This is how far i tested it for now.
danielfalck
Posts: 395
Joined: Fri Oct 07, 2011 8:58 pm
Location: Beaverton,Oregon, USA
Contact:

Re: libarea, used in Path Workbench

Post by danielfalck »

triplus wrote:As for the compiling (and PPA) documentation needs to be updated for new dependency. For Ubuntu:

Code: Select all

libboost-python-dev
Beyond that it compiles fine on Ubuntu. There is something i would like to see changed if possible. Running cmake infroms the user libarea will be installed in /usr/local/lib folder but what would be nice is to be able to run FreeCAD after compiling it and to have fully functional Path WB without actually making the install. This is how far i tested it for now.
Thanks for checking this out.

I used CMAKE_INSTALL_LIBDIR , similar to what I saw in other workbenches. In the past,on linux systems, it was installed in the /usr/local/lib/python2.7/dist-packages/ so that python could import it.
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: libarea, used in Path Workbench

Post by triplus »

danielfalck wrote:
triplus wrote:As for the compiling (and PPA) documentation needs to be updated for new dependency. For Ubuntu:

Code: Select all

libboost-python-dev
Beyond that it compiles fine on Ubuntu. There is something i would like to see changed if possible. Running cmake infroms the user libarea will be installed in /usr/local/lib folder but what would be nice is to be able to run FreeCAD after compiling it and to have fully functional Path WB without actually making the install. This is how far i tested it for now.
Thanks for checking this out.

I used CMAKE_INSTALL_LIBDIR , similar to what I saw in other workbenches. In the past,on linux systems, it was installed in the /usr/local/lib/python2.7/dist-packages/ so that python could import it.
I see. I don't have much experience with this and looking at:

https://github.com/danielfalck/FreeCAD/ ... 7d1ecafa7f

Before the path was relative and therefore one could run ./bin/FreeCAD directly after compile and get fully functional Path WB? But currently libarea path is set as absolute path and therefore libarea has to be installed to /usr/local/lib first for ./bin/FreeCAD to pick it up?
User avatar
yorik
Founder
Posts: 13665
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: libarea, used in Path Workbench

Post by yorik »

If the area lib is together with the other freecad libs, then freecad will pick it up automatically. I think this is the correct way to do it, all libraries compiled together with freecad should stay together and not go to system folders...

Couldn't test yet, but I will do ASAP!
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: libarea, used in Path Workbench

Post by triplus »

yorik wrote:If the area lib is together with the other freecad libs, then freecad will pick it up automatically. I think this is the correct way to do it, all libraries compiled together with freecad should stay together and not go to system folders...

Couldn't test yet, but I will do ASAP!
Sounds good.

P.S. I am wondering will Debian complain we "embedded" libarea in FreeCAD?
User avatar
sgrogan
Veteran
Posts: 6499
Joined: Wed Oct 22, 2014 5:02 pm

Re: libarea, used in Path Workbench

Post by sgrogan »

yorik wrote:If the area lib is together with the other freecad libs, then freecad will pick it up automatically. I think this is the correct way to do it, all libraries compiled together with freecad should stay together and not go to system folders...
Thanks for commenting Yorik.

area.pyd (area.so on Linux) is just another FreeCAD module under this scenario. Just like the Path module itself. Path.pyd and PathGui.pyd are located in /Mod/Path. So should area.pyd go into /Mod/Path or /Mod/Path/libarea? Will FreeCAD search recursively one level deeper into /libarea?
triplus wrote: P.S. I am wondering will Debian complain we "embedded" libarea in FreeCAD?
Someone please correct me if I'm wrong, but isn't this the reason danielfalck created his branch? This cleans up all the license issues?
"fight the good fight"
User avatar
yorik
Founder
Posts: 13665
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: libarea, used in Path Workbench

Post by yorik »

sgrogan wrote: Will FreeCAD search recursively one level deeper into /libarea?
No. It should be in one of the folders from the list you get from inside FreeCAD:

Code: Select all

import sys
print sys.path
About Debian, no, freecad already embeds several other libraries (kdl, pycxx, wildmagic, etc). As long as there is no license incompatibility, there is no problem.
danielfalck
Posts: 395
Joined: Fri Oct 07, 2011 8:58 pm
Location: Beaverton,Oregon, USA
Contact:

Re: libarea, used in Path Workbench

Post by danielfalck »

sgrogan wrote:
yorik wrote:If the area lib is together with the other freecad libs, then freecad will pick it up automatically. I think this is the correct way to do it, all libraries compiled together with freecad should stay together and not go to system folders...
Thanks for commenting Yorik.

area.pyd (area.so on Linux) is just another FreeCAD module under this scenario. Just like the Path module itself. Path.pyd and PathGui.pyd are located in /Mod/Path. So should area.pyd go into /Mod/Path or /Mod/Path/libarea? Will FreeCAD search recursively one level deeper into /libarea?
triplus wrote: P.S. I am wondering will Debian complain we "embedded" libarea in FreeCAD?
Someone please correct me if I'm wrong, but isn't this the reason danielfalck created his branch? This cleans up all the license issues?

Yes, I created that branch for two reasons- number 1 to clean up the licensing, number 2 to make it easier to install the Path Workbench.
I don't plan on asking to merge my branch into Master until I have rock solid 'New BSD' headers in all the files and have the CmakeLists.txt file worked out.
Post Reply