Assembly3 preview

Discussion about the development of the Assembly workbench.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: Assembly3 preview

Post by wsteffe »

wsteffe wrote: Sat Dec 29, 2018 9:29 am Any missing reference will be explicitly shown to user, who will have the choice of either manually re-attach
If I have understood correctly this means that, in your LinkDev branch, if a sketch constraint refers to an external object that is lost, that object is copied locally and becomes detached from the original referred object. So the constraint itself needs not to be deleted.
It sounds very good. I am looking forward to see it in the LinkStage3.
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: Assembly3 preview

Post by wsteffe »

Hello realthunder

Yesterday I spent some time reading the assembly 3 tutorials.

I like very much the idea of putting the referred objects into a separate element group.
In fact I think the this choice can simplify a lot the magagement/fixing of broken links which typically occur after having modified an object referred in the upper assembly.
Somewhere you wrote that the element group serves as a formal declaration of interfaces referred from the outside of the given subassembly. You also said that is a good habit to make this declaration explicitly.

But then why not make explicit also the purpose of the element group by calling it "interface" group, or any other term which can better clarify that purpose ?
realthunder
Veteran
Posts: 2190
Joined: Tue Jan 03, 2017 10:55 am

Re: Assembly3 preview

Post by realthunder »

wsteffe wrote: Sat Dec 29, 2018 10:08 am If I have understood correctly this means that, in your LinkDev branch, if a sketch constraint refers to an external object that is lost, that object is copied locally and becomes detached from the original referred object. So the constraint itself needs not to be deleted.
The external geometries in sketch are projected into sketch plane, so they are always copied. But the upstream sketch does not save the external geometry into file, they are always rebuilt when restoring. In addition, the copied geometries are kept in an array in the exact order of the reference links. Any missing reference will cause great trouble. I have changed it to save the external geometry and use a map from reference to index. The user now has full control of how to deal with a missing reference.

wsteffe wrote: Sat Dec 29, 2018 10:35 am But then why not make explicit also the purpose of the element group by calling it "interface" group, or any other term which can better clarify that purpose ?
Well, I don't want to force the user to use the workbench in one way. They can still add objects directly and select two elements and create the constraint. In this way, the element group contains internal elements that are used by the assembly itself instead of the upper level, so they are not considered as interface in this case.
Try Assembly3 with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: Assembly3 preview

Post by triplus »

triplus wrote: Fri Dec 28, 2018 2:31 pm For now, you can use the "Replace with link" trick as I shown below. If you want to link across different document. Simply copy the original object, such as the sketch here to a new document, and then go back and change the link. Make sure you have at least saved once both the linking and linked documents.

phpBB [video]
Thanks for the tutorial. I guess, by using the trick, basically doing what i tried to do, but in reverse order for now! ;)
It should be easy to do, we've already have feature like Part::Face.
If you ever decide to add or explore such parametric features. I was thinking, as this are basic geometry building blocks, maybe introducing a new toolbar and adding the features, as a set of standalone commands, could make sense? For example Point, Line, Wire, Face, Shell, Solid. Line feature would therefore have 2 Point features underneath it (or if possible i guess 2 existing vertices selected from other features)? I have always missed the possibility, of using such direct parametric modeling approach, by having access to basic geometry building blocks in FreeCAD.

It's already easy to create a Pyramid with Part_Shapebuilder and using some Part/Draft Points:
Pyramid.png
Pyramid.png (3.16 KiB) Viewed 2038 times
What is currently missing is some straightforward way to for example move one Point. Well currently nothing really happens after, as only the Point itself moves. If that could change in the future and such Point would basically became a parametric node. Controlling Lines -> Faces -> Shell -> Solid, that would be great. I know, i would be using such toolbar quite often!
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: Assembly3 preview

Post by wsteffe »

realthunder wrote: Sat Dec 29, 2018 11:14 pm They can still add objects directly and select two elements and create the constraint. In this way, the element group contains internal elements that are used by the assembly itself instead of the upper level, so they are not considered as interface in this case.
In the "Concepts" section of your Design wiki you wrote the following sentence: "Any constraint involving some assembly will only indirectly link to the geometry element through an Element of some child assembly."

And in my view this is a key property which gives a special meaning to the element group: Any constraint reference must pass through an element which belongs to the element group.

A user could put into the elements group also things that are not referred by any constraint. But I really can not see why he should do that.
If he wants to have a geometrical entity in a group named "elements" he may simply create that group without using the interface group.
User avatar
ceremcem
Posts: 226
Joined: Sun Jan 07, 2018 11:10 am

Re: Assembly3 preview

Post by ceremcem »

wsteffe wrote: Sun Dec 30, 2018 10:04 am And in my view this is a key property which gives a special meaning to the element group: Any constraint reference must pass through an element which belongs to the element group.

I think quite the same. In my perspective, "Element"s are "Handles" and "Element Group" is the "Interface" of the component. With a circuit analogy, "Element"s are "Pin"s and "Element Group" is the "Pinout" (thus the "Interface") of the component:

Image

As an another analogy, "Element"s are "Functions/methods" and "Element Group" is the "API" (Application Programming Interface, thus the "Interface") in this case.
A user could put into the elements group also things that are not referred by any constraint. But I really can not see why he should do that.
I usually do (or try to do) that. Since every model/component is a sub-model/sub-component according to the next level of the "project", I'm simply declaring the "Interface" for the upper level of assembly. There is no such thing as "top level assembly" in my perspective. Every assembly is potentially a sub-assembly for another possible project.
realthunder
Veteran
Posts: 2190
Joined: Tue Jan 03, 2017 10:55 am

Re: Assembly3 preview

Post by realthunder »

wsteffe wrote: Sun Dec 30, 2018 10:04 am And in my view this is a key property which gives a special meaning to the element group: Any constraint reference must pass through an element which belongs to the element group.
That is true. Every element inside any constraint is indeed a link to the real element object, which may in turn links to to another element in lower level assembly. However, there must be a bottom level assembly, where the element inside actually links to the geometry object. The way I recommend is to wrap each geometry model inside an assembly container, and manually create elements inside to define its interface to be used by higher hierarchy. No constraint will be create inside this bottom level assembly, since there is only one geometry model. But it can be inconvenient from time to time, where the user just what some quick try. So I do allow adding multiple geometry models inside a bottom level assembly, and therefore the constraints created inside this kind of assembly uses elements inside its own element group. If we follow the software terminology, this self using elements are like private attributes. But I don't want to make the assembly container structure too complicated, so I didn't make that distinction.
Try Assembly3 with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
User avatar
saso
Veteran
Posts: 1924
Joined: Fri May 16, 2014 1:14 pm
Contact:

Re: Assembly3 preview

Post by saso »

Catia - Publication
NX - Product Interface

And if you follow the model hierarchy concept I showed here https://forum.freecadweb.org/viewtopic. ... 13#p276313 then you will understand that FreeCAD - Sketch Exports (Catia - Sketch Outputs), follow the same idea but for sketches.
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: Assembly3 preview

Post by wsteffe »

wsteffe wrote: Sun Dec 30, 2018 10:04 am I usually do (or try to do) that. Since every model/component is a sub-model/sub-component according to the next level of the "project",
I do the same but I was meaning a different thing and, to be more clear, I I should have said:
"A user could put into the elements group also things that are not meant to be referred by any upper level constraint."

An
wsteffe wrote: Sun Dec 30, 2018 10:04 am As an another analogy, , "Element"s are "Functions/methods" ...
A third analogy, which in my view is very instructive to catch the spirit of the interfaces, can be taken from a complex project (organized in a hierarchy of sub-projects) which is carried out in an industrial organization.
In a typical situation the different projects are done in parallel by different industrial units. At the beginning these units have to agree on a set of interfaces so that at the end is will be possible to assemble each system from its subsystems.
If you are the responsible of a given subsystem you will have to declare in the interfaces all what is needed to properly define the upper level system but you will not declare (which means freeze) other inner details of your project because otherwise you would limit your design freedom.
realthunder
Veteran
Posts: 2190
Joined: Tue Jan 03, 2017 10:55 am

Re: Assembly3 preview

Post by realthunder »

triplus wrote: Sat Dec 29, 2018 11:58 pm If you ever decide to add or explore such parametric features. I was thinking, as this are basic geometry building blocks, maybe introducing a new toolbar and adding the features, as a set of standalone commands, could make sense?
I think a single feature can do all of these. It can easily detect the intended type of shape to build by checking its children shape type. For any child vertex, it creates an edge, and so on.
Try Assembly3 with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
Post Reply