Handbuch:Parametrische Objekte

From FreeCAD Documentation
Revision as of 14:11, 19 January 2020 by Maker (talk | contribs) (Created page with "Alle Zwischenbearbeitungen (2D Formen, Polster, Tasche, usw.) sind immer noch vorhanden, und Du kannst immer noch jeden ihrer Parameter jederzeit ändern. Die gesamte Kette wi...")

{{Docnav/de |[[Manual:The FreeCAD document/de|Das FreeCAD Dokument] ]|Import und Export in andere Dateitypen|Handbuch: Start |IconC = Crystal Clear manual.png }}

FreeCAD ist für die parametrische Modellierung konzipiert. Das bedeutet, dass die Geometrie, die du erstellst, nicht frei modellierbar ist, sondern durch Regeln und Parameter erzeugt wird. Zum Beispiel kann ein Zylinder aus einem Radius und einer Höhe erzeugt werden. Mit diesen beiden Parametern hat das Programm genügend Informationen, um den Zylinder zu bauen.

Parametrische Objekte sind in FreeCAD in Wirklichkeit kleine Teile eines Programms, die immer dann laufen, wenn sich einer der Parameter geändert hat. Objekte können viele verschiedene Arten von Parametern haben: Zahlen (ganze Zahlen wie 1, 2, 3 oder Fließkommazahlen wie 3.1416), reale Größen (1mm, 2.4m, 4.5ft), (x,y,z) Koordinaten, Textstrings ("Hallo!") oder sogar ein anderes Objekt.

Dieser letzte Typ erlaubt es, schnell komplexe Ketten von Operationen zu erstellen, wobei jedes neue Objekt auf einem vorhergehenden Objekt basiert und diesem neue Funktionen hinzufügt.

Im folgenden Beispiel basiert ein massives, würfelförmiges Objekt (Polster) auf einer rechteckigen 2D Form (Skizze) und hat einen Extrusionsabstand. Mit diesen beiden Eigenschaften erzeugt es eine feste Form, indem es die Grundform um den angegebenen Abstand extrudiert. Du kannst dieses Objekt dann als Basis für weitere Operationen verwenden, wie z.B. das Zeichnen einer neuen 2D Form auf einer seiner Flächen (Sketch001) und dann eine Subtraktion (Tasche), bis du zu deinem endgültigen Objekt kommst.

Alle Zwischenbearbeitungen (2D Formen, Polster, Tasche, usw.) sind immer noch vorhanden, und Du kannst immer noch jeden ihrer Parameter jederzeit ändern. Die gesamte Kette wird bei Bedarf neu aufgebaut (neu berechnet).

Two important things are necessary to know:

  1. Recomputation is not always automatic. Heavy operations, that might modify a big portion of your document, and therefore take some time, are not performed automatically. Instead, the object (and all the objects that depend on it) will be marked for recomputation (a small blue icon appears on them in the tree view). You must then press the recompute button (or Edit->Refresh) to have all the marked objects recomputed.
  2. The dependency tree must always flow in the same direction. Loops are forbidden. (See DAG, and DAG view) You can have object A which depends on object B which depend on object C. But you cannot have object A which depends on object B which depends on object A. That would be a circular dependency. However, you can have many objects that depend on the same object, for example objects B and C both depend on A. Menu Tools -> Dependency graph shows you a dependency diagram like on the image above. It can be useful to detect problems.

Not all objects are parametric in FreeCAD. Often, the geometry that you import from other files won't contain any parameter, and will be simple, non-parametric objects. However, these can often be used as a base, or starting point for newly created parametric objects, depending, of course, on what the parametric object requires and the quality of the imported geometry.

All objects, however, parametric or not, will have a couple of basic parameters, such as a Name, which is unique in the document and cannot be edited, a Label, which is a user-defined name that can be edited, and a placement, which holds its position in the 3D space.

Finally, it is worth noting that custom parametric objects are easy to program in python.

Read more