Issue #6273 - Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
chrisb
Veteran
Posts: 53785
Joined: Tue Mar 17, 2015 9:14 am

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by chrisb »

I have created a new ShapeBinder, and that works as expected - but only with a single slot. If I toggle another slot from construction to real geometry it fails again.
Attachments
SM-PLB03A_cb.FCStd
(43.46 KiB) Downloaded 27 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 53785
Joined: Tue Mar 17, 2015 9:14 am

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by chrisb »

The new ShapeBinder works properly with multiple slots if I map the sketches on XY plane instead of XZ.
Attachments
SM-PLB03A_XY_cb.FCStd
(39.09 KiB) Downloaded 27 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
bruce
Posts: 47
Joined: Sun Aug 11, 2019 8:46 pm

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by bruce »

@chrisb, I agree with your findings.

Is there any further action I can take/information I can supply that will be helpful? Assuming this is not the intended behaviour?
chrisb
Veteran
Posts: 53785
Joined: Tue Mar 17, 2015 9:14 am

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by chrisb »

Werner has already participated in this topic, so let's wait if he or somebody else contributes some more insights. If not, then you should create a bug report. At least the different behaviour in XY- and XZ-plane is a bug.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
freedman
Veteran
Posts: 3415
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by freedman »

Attached is a test. Body is two sketches; Block, and sketch002 which is 4 holes pocketed. Body001 is a block on top the other and a subshapebinder of the holes. I pocketed the binder and step increased the dimension pocket. Notice in the pic the two distant holes are creating a pocket but the two nearer holes
did not work. Using 0.20.259
My thoughts on this are per the documentation. It states:
The SubShapeBinder is derived from Part Feature (Part::Feature class). I think this means you can make subshapebinders of solids and use those solids in booleans or the faces to derive pads. I didn't read anything that stated we could use a sketch for a cutting tool.

That being said: I hope this can work and we can get it to work :) , it would redefine how we could use the Master sketch.
My 2 cents.
Attachments
Sub_binder1.FCStd
(73.25 KiB) Downloaded 23 times
sub11.png
sub11.png (177.84 KiB) Viewed 1509 times
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by TheMarkster »

As an experiment I used Part::Extrude on the shapebinder and it worked. I set the LengthFwd to 49mm so it would reach through and set the Reversed property to True so it went in the desired direction. At first it doesn't show that it is intersecting because the Extrude is not yet inside the Body, which has been repositioned. Once inside the Body it uses the Body's LCS to position itself correctly relative to the shapebinder. The screenshot below is after putting the Extrude into the Body.
Snip macro screenshot-a1a378.png
Snip macro screenshot-a1a378.png (101.24 KiB) Viewed 1487 times
Extrude takes on the color of the shapebinder, so you get this weird golden colored object.

I then used PDWrapper macro (available in the addon manager) to put the Extrude into the body as a subtractive type to make the cut. Usage: select the Extrude, run the macro, choose Subtractive as the type when prompted since we want to make a cut with it.
Snip macro screenshot-2245b4.png
Snip macro screenshot-2245b4.png (94.35 KiB) Viewed 1487 times
You need PDWrapper installed and you need to run it once to create the pdwrapper.py file before opening the .FCStd file or else the object won't have the necessary class information loaded into memory to work. I just pushed 0.2021.10.16.rev2, which has some bug fixes in it, so update if you already have it installed.
Attachments
SM-PLB03A case_markster.FCStd
(681.09 KiB) Downloaded 25 times
freedman
Veteran
Posts: 3415
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by freedman »

Just like that!
I have got to find some time to learn to be a wrapper. Nice work.
bruce
Posts: 47
Joined: Sun Aug 11, 2019 8:46 pm

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by bruce »

@TheMarkster

Thanks for showing how this can be done.

To the developers at large:

I would argue that although @TheMarksters solution works, this should not be the accepted solution to this problem, given what the documentation states, i ought to be able to immediately create a pocket from a subshapebinder on any axis.

Additionally, as a user who's not super good with the software, I do not like having to switch modelling toolkits or bring in plugins in the midst of modelling a part, maybe my reasons are not sound, but I get the impression when I jump across modelling toolkits I'm inviting disaster.

I submit that being able to model a part in a singular toolkit drastically reduces the learning curve on the software, and will help build engagement.

Thanks again for all your hard work on this.
drmacro
Veteran
Posts: 8806
Joined: Sun Mar 02, 2014 4:35 pm

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by drmacro »

bruce wrote: Sun Oct 17, 2021 3:35 pm ...
Additionally, as a user who's not super good with the software, I do not like having to switch modelling toolkits or bring in plugins in the midst of modelling a part, maybe my reasons are not sound, but I get the impression when I jump across modelling toolkits I'm inviting disaster.

I submit that being able to model a part in a singular toolkit drastically reduces the learning curve on the software, and will help build engagement.
...
This is just the observation of a cantankerous old fool, so, don't take it too seriously... :mrgreen:

As a novice user this may seem like a valid argument.

As an experienced user, I expect to use all facets of the tool at hand and expect to switch to different "toolkits" as part of using the software's capabilities to it's fullest. And I certainly don't want all the tools on the screen all the time.

Sometimes I use a ratchet wrench, sometimes and open end, and other times a power tool...they are in different drawers of my toolbox, otherwise my toolbox is so cluttered I can't find any of them.

The approach to part you have here does require the use of multiple workbenches. It could be done in Part only or Part Design only.
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
bruce
Posts: 47
Joined: Sun Aug 11, 2019 8:46 pm

Re: Padding/pocketing sub shapebinders on not the Z axis doesn't work

Post by bruce »

As an experienced user, I expect to use all facets of the tool at hand and expect to switch to different "toolkits" as part of using the software's capabilities to it's fullest. And I certainly don't want all the tools on the screen all the time.
@drmacro Thank you for your thoughts on this. Allow me to respond:

I'd counter that a physical analogy to a complicated piece of software is a not well founded. When I use hand and power tools, it's clearly understood what I'm doing (rotating, drilling, tapping, fastening, etc.), there's nothing happening "under the hood" that I need to worry about - I can clearly see the change I'm making on the workpiece. There is no hidden state.

FreeCAD necessarily hides a good deal of the model complexity and state away, and I cannot easily infer a lot of the changes (I probably wouldn't understand them that well either). Mixing toolkits creates the possibility that the operations of one *modelling* toolkit may or may not be compatible with that of another *modelling* toolkit (to be clear, having FEM, page layout, assembly, etc. as separate toolkits makes total sense - they're orthogonal operations). Arbitrary plugins (while nice to accomplish specific tasks) introduce the possibility of even more hidden (?and non-encapsulated?) arbitrary state that I cannot understand. This is all amplified by the parametric model where changes to the model multiple steps ago will cascade throughout the model in possibly unpredictable ways.

For FreeCAD to be successful (Which I define as making 3D modelling a 'solved problem' wherein you wouldn't even consider another product - why would you? This is the best and it's free - see Wireshark) it needs to be intuitive. Having to switch workbenches or invoke plugins to accomplish the same class of task goes against that, especially when the possibility of incompatibilities (?are perceived to?) exist.

Again, thanks to all those who work on this. I hope my input has some value.
Post Reply