Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
townkat
Posts: 10
Joined: Mon Sep 09, 2019 10:42 pm

Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby townkat » Thu Sep 12, 2019 11:32 pm

(As the idea in my other topic changed I thought to create a new one to avoid confusion.)

In short, I would love an option in the PartDesign Pocket tool that would allow us to change the function of Pocket from removing the extruded sketch and keeping the rest to removing the rest and keeping the extruded sketch (in other words, from subtract to intersect).
Probably a drop-down list with possible functions would be nice (subtract/intersect), or maybe an 'invert' checkbox.

This function would help me a lot by removing the need to invert the shape when I draw it in Sketcher. (manual inverting the sketch is really not easy)

I'am thinking to fill in a feature request for this in the tracker but I thought that debating a little bit more before could help fill in a more clear request there.

Thank you.
chrisb
Posts: 17520
Joined: Tue Mar 17, 2015 9:14 am

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby chrisb » Fri Sep 13, 2019 12:20 am

Thank you for discussing this here first, that's how the process should be.

At first thought this sounds reasonable, even if it were only for the sake of completeness of functions. But you may give some examples, because I never had any difficulties in designing an appropriate sketch using the currently available features.
townkat
Posts: 10
Joined: Mon Sep 09, 2019 10:42 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby townkat » Fri Sep 13, 2019 3:18 am

I attached a model that I have drawn some time ago. Actually I had made it in many variants so the struggle was even bigger.
I am not sure it is the best example. I can search more if it is not explanatory enough.

I renamed the related sketches and pockets with an "i" at the end (from inverted), and also let the related sketches visible.
The last 2 sketches (147 and 148) , would surely be easier to be drawn in the non inverted shape. They also had to be splitted in 2 shapes to achieve the same result. This happens pretty often when I want to optimize the shape of the object by removing the unnecessary material. Even if I know what shape I want it to have after the process I have to think at the parts which must be removed, and also do extra math for their dimensions too (the inversion that i was talking about). I think it is also a bit counter-intuitive in this situations.

Thank you.
Attachments
exemple 1.FCStd
(187.04 KiB) Downloaded 5 times
kisolre
Posts: 1243
Joined: Wed Nov 21, 2018 1:13 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby kisolre » Fri Sep 13, 2019 4:56 am

I started similar topic some time ago - expose common boolean operation in Part Design (can find it now). But in the end it turned quite easy to achieve that - just draw the desired shape and then create a bigger recrangle around everything previous and pocket with that. I still think that dedicated tool would be nice.
townkat
Posts: 10
Joined: Mon Sep 09, 2019 10:42 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby townkat » Fri Sep 13, 2019 7:08 pm

kisolre wrote:
Fri Sep 13, 2019 4:56 am
just draw the desired shape and then create a bigger rectangle around everything previous and pocket with that.
Good tip, thank you, but I just tried it and it does not work directly, the sketch must also be modified and then into a bigger and harder to make drawing (ex: try on Sketch147i in my "example 1.FCStd") .

Still, it would be just a workaround, I would still hope for the implementation of my requested feature :) .
Last edited by townkat on Fri Sep 13, 2019 10:03 pm, edited 1 time in total.
vocx
Posts: 986
Joined: Thu Oct 18, 2018 9:18 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby vocx » Fri Sep 13, 2019 7:31 pm

kisolre wrote:
Fri Sep 13, 2019 4:56 am
...draw the desired shape and then create a bigger recrangle around everything previous and pocket with that. I still think that dedicated tool would be nice.
I couldn't remember the name of the thread, but yes, this is basically a Part Common (intersection) feature.

See Native PartDesign Common feature.
kisolre
Posts: 1243
Joined: Wed Nov 21, 2018 1:13 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby kisolre » Fri Sep 13, 2019 7:53 pm

vocx wrote:
Fri Sep 13, 2019 7:31 pm
See Native PartDesign Common feature.
Thats the thread.
townkat wrote:
Fri Sep 13, 2019 7:08 pm
(ex: try on Sketch147i in my "example 1.FCStd") .
It does not have to be pretty :)
Attachments
InversePocket.JPG
InversePocket.JPG (44.78 KiB) Viewed 200 times
InversePocket_result.JPG
InversePocket_result.JPG (85.2 KiB) Viewed 200 times
townkat
Posts: 10
Joined: Mon Sep 09, 2019 10:42 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby townkat » Fri Sep 13, 2019 10:27 pm

kisolre wrote:
Fri Sep 13, 2019 7:53 pm
It does not have to be pretty :)
Thnx. Yes, it does work that way. Actually I tried to recreate the method and made an even uglier one :).

Great workaround in the meantime.
I still hope the PartDesign Common feature will be available sometime.

I do not think a feature request in the tracker is still necessary, as the developers seem to know about this idea.

Thank you all.
Last edited by Kunda1 on Fri Sep 13, 2019 11:15 pm, edited 1 time in total.
Reason: Bbcode fix
chrisb
Posts: 17520
Joined: Tue Mar 17, 2015 9:14 am

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby chrisb » Sat Sep 14, 2019 1:22 am

I hd asked for examples, because I usually use the technique by kisolre. I had wrongly assumed this was common knowledge :geek: . However, the "outer rectangle technique" doesn't work anymore if you have already nested geometry:
Snip macro screenshot-fa81bb.png
Snip macro screenshot-fa81bb.png (4.26 KiB) Viewed 177 times
.

It would take two pockets vs. one common to create the flattened tube. Please note that this is only for demontration, I know that such model could be created using just one pad.
openBrain
Posts: 1815
Joined: Fri Nov 09, 2018 5:38 pm

Re: Feature Request: PartDesign Pocket, add intersect option in addition to subtract

Postby openBrain » Sat Sep 14, 2019 8:13 am

kisolre wrote:
Fri Sep 13, 2019 7:53 pm
townkat wrote:
Fri Sep 13, 2019 7:08 pm
(ex: try on Sketch147i in my "example 1.FCStd") .
It does not have to be pretty :)
Just want to remember that for robustness purpose, you can bind the dimensions of the outer rectangle with latest Pad shape, adding some margin.
In this example, you could use eg . :
  • Pad063.Shape.BoundBox.XLength
  • or
  • Pad063.Shape.BoundBox.XMin
  • Pad063.Shape.BoundBox.XMax
Same exists for Y & Z axis. ;)