PartDesign Next

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
cox
Posts: 971
Joined: Wed Nov 26, 2014 11:37 pm

Re: PartDesign Next

Post by cox »

If i have a single sketch in a body and copy & paste this. The copy is placed outside the active body and not visible, Moving the sketch to the body(drag and drop do not work) it becomes visible but black.
Screenshot_20160419_182633.png
Screenshot_20160419_182633.png (13.16 KiB) Viewed 2088 times
EDIT: Opening this file I get both sketches black?
Attachments
copy sketch.fcstd
(8.58 KiB) Downloaded 51 times
Need help? Feel free to ask, but please read the guidelines first
cox
Posts: 971
Joined: Wed Nov 26, 2014 11:37 pm

Re: PartDesign Next

Post by cox »

DeepSOIC wrote:
cox wrote:advice if you can reproduce and if I should make bug report in mantis
Nope, I can't reproduce. Both Sketch and Sketch001 react to editing superPlacement.
screencast1.gif
screencast1.gif (662.64 KiB) Viewed 2000 times
I do not understand why this trouble should only apply to me, could it be OS dependant, i have cleaned out my build directory and rebuilt on only one core.

Please try to reproduce on more OS's according to screencast

OS: "Arch Linux"
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.7423 (Git)
Build type: Unknown
Branch: master
Hash: bfaa8799edba35ae1609edb6205aaeacf37b73ff
Python version: 2.7.11
Qt version: 4.8.7
Coin version: 3.1.3
OCC version: 6.9.1
Need help? Feel free to ask, but please read the guidelines first
User avatar
DeepSOIC
Veteran
Posts: 7900
Joined: Fri Aug 29, 2014 12:45 am
Location: used to be Saint-Petersburg, Russia

Re: PartDesign Next

Post by DeepSOIC »

Ah, you are editing it by clicking that button, not directly from property editor. OK, got it. I'll try to fix, but it may be tricky. I think it's because Placement task dialog actually edits Placement property, not superPlacement...
cox
Posts: 971
Joined: Wed Nov 26, 2014 11:37 pm

Re: PartDesign Next

Post by cox »

DeepSOIC wrote:I think it's because Placement task dialog actually edits Placement property, not superPlacement...
I get the same effect when editing the sketch's placement the same way with button.

I find the placement and superplacement concepts confusing.
I guess the placement is global and super is local offset referencing the containing body/part.
Does this mean that placement only has effect on root level body/part/sketch objects? and superplacement only affects objects contained in other body/part objects.

If this is true, is it necessary to display the placment property in contained objects and is it necessary to display the superplacment in root objects?

And if this is true, why differentiate the placement with two different properties when one placement property could be differentiated by its objects placement in the tree?

If the object i question is a root object the placement property is used as global, and if the object has parent the placement is used as offset from parent?


I have a feeling this is done so that all objects has a cached global placement to make calculation more efficient.
Need help? Feel free to ask, but please read the guidelines first
User avatar
DeepSOIC
Veteran
Posts: 7900
Joined: Fri Aug 29, 2014 12:45 am
Location: used to be Saint-Petersburg, Russia

Re: PartDesign Next

Post by DeepSOIC »

cox wrote:I find the placement and superplacement concepts confusing. I guess the placement is global and super is local offset referencing the containing body/part.
That needs a wiki page of course ;)

Placement is working just like it did for sketches attached to faces in legacy PartDesign. Once a sketch is attached, its Placement it reset to follow attachment upon every recompute.

Then, there were two offset properties in early PartDesign Next datum features code. When I was transplanting these datum features to attacher, I realized I can replace these offsets with unclear and mode-dependent behavior with superPlacement.
So superPlacement is extra placement to apply on top of placement calculated by attacher. I can't use Placement for this purpose, because it would need to be preserved in some wonderful way, yet be changed by attacher to follow the changes of object.

superPlacement is only active when something is attached. It something is not attached, superPlacement does nothing.
Placement is the final overall placement of something. When the something is attached, Placement is overwritten by attachment upon every recompute, and thus is effectively read-only. I should gray it out in property editor.
triplus
Veteran
Posts: 9472
Joined: Mon Dec 12, 2011 4:45 pm

Re: PartDesign Next

Post by triplus »

Therefore basically super placement adds additional possibility to offset the attachment from the attachment base?
cox
Posts: 971
Joined: Wed Nov 26, 2014 11:37 pm

Re: PartDesign Next

Post by cox »

Thanks @DeepSOIC and @triplus for good clarifications. :D
Need help? Feel free to ask, but please read the guidelines first
cox
Posts: 971
Joined: Wed Nov 26, 2014 11:37 pm

Re: PartDesign Next

Post by cox »

I have been testing the Shape binder, and have found that it seams to have problems when the source face is in the xz plane. It creates the Shape binder object, oriented in the xy plane.

Create a sketch in xz plane in a body(if you create in xy, this does not happen), pad and make a Shape binder feature on face on top of pad .

Please verify my findings, this feels like a bug to me. I will file it upon confirmation.

Funny thing is that, if I try to make a Shape binder of the opposite face(original sketch) it creates Identical Shape binder with identical placement.

Creating a Shape binder on one of the other faces(have not tested all :D ) produces nice in place binder.
Screenshot_20160501_214856.png
Screenshot_20160501_214856.png (19.41 KiB) Viewed 1693 times
Attachments
Shape binder plane swap xz to xy.fcstd
(28.14 KiB) Downloaded 48 times
Need help? Feel free to ask, but please read the guidelines first
Post Reply