Part TopoShape/de: Difference between revisions
(Created page with "==Kurzanleitung==") |
(Created page with "Die Part TopoForm ist ein Objekt, das einigen Anwendung DokumentObjekte zugeordnet ist.") |
||
Line 13: | Line 13: | ||
==Kurzanleitung== |
==Kurzanleitung== |
||
Die Part TopoForm ist ein Objekt, das einigen [[App_DocumentObject/de|Anwendung DokumentObjekte]] zugeordnet ist. |
|||
In particular, the basic object that handles these types of attributes is the [[Part_Feature|Part Feature]] ({{incode|Part::Feature}} class). All objects derived from this class will have access to a Part TopoShape. |
In particular, the basic object that handles these types of attributes is the [[Part_Feature|Part Feature]] ({{incode|Part::Feature}} class). All objects derived from this class will have access to a Part TopoShape. |
Revision as of 15:18, 17 January 2020
Einleitung
Eine Part TopoForm, oder formal eine Part::TopoShape, ist eine Klasse, die eine parametrische 'topologische Form in der Software definiert. Objekte im Dokument, die etwas in der 3D Ansicht zeigen, haben normalerweise eine TopoForm.
Die topologischen Formen sowie deren Methoden werden durch den OpenCASCADE Technology Kernel (OCCT) definiert. FreeCAD verwendet diese Formen und baut Anwendung DokumentObjekte um sie herum.
Vereinfachtes Diagramm der Beziehungen zwischen den Kernobjekten im Programm. Die Klasse Part::TopoShape
wird in das Part::Feature
Objekt eingebettet und von dort aus an alle davon abgeleiteten Objekte verbreitet.
Kurzanleitung
Die Part TopoForm ist ein Objekt, das einigen Anwendung DokumentObjekte zugeordnet ist.
In particular, the basic object that handles these types of attributes is the Part Feature (Part::Feature
class). All objects derived from this class will have access to a Part TopoShape.
Some of the most important objects with Part TopoShape are the following:
- Any primitive solid created with the Part Workbench.
- Any PartDesign Body and PartDesign Feature created with the PartDesign Workbench.
- Any object derived from Part Part2DObject, like most objects created with the Draft Workbench.
- Any sketch, that is, Sketcher SketchObject, created with the Sketcher Workbench.
- Any object created by importing a STEP, BREP, and similar solid format files.
Scripting
See also: FreeCAD Scripting Basics, and scripted objects.
All objects derived from Part::Feature
will have a Part TopoShape, which is normally accessible from its Shape
attribute.
import FreeCAD as App
doc = App.newDocument()
obj = App.ActiveDocument.addObject("Part::Box", "Box")
print(obj.Shape)
A TopoShape has many attributes (variables) and methods that contain information about it, and which allow doing operations with it. These variables and methods can be tested in the Python console.
print(obj.Shape.Area)
print(obj.Shape.BoundBox)
print(obj.Shape.CenterOfMass)
print(obj.Shape.ShapeType)
obj.Shape.check()
obj.Shape.copy()
obj.Shape.exportStep("my_file.step")
obj.Shape.exportStl("my_file.stl")
For a full list of attributes and methods, consult the source documentation, and the Std PythonHelp tool.
- Primitives: Box, Cylinder, Sphere, Cone, Torus, Tube, Create primitives, Shape builder
- Creation and modification: Extrude, Revolve, Mirror, Fillet, Chamfer, Make face from wires, Ruled Surface, Loft, Sweep, Section, Cross sections, 3D Offset, 2D Offset, Thickness, Projection on surface, Attachment
- Boolean: Make compound, Explode Compound, Compound Filter, Boolean, Cut, Fuse, Common, Connect, Embed, Cutout, Boolean fragments, Slice apart, Slice, XOR
- Measure: Measure Linear, Measure Angular, Measure Refresh, Clear All, Toggle All, Toggle 3D, Toggle Delta
- Getting started
- Installation: Download, Windows, Linux, Mac, Additional components, Docker, AppImage, Ubuntu Snap
- Basics: About FreeCAD, Interface, Mouse navigation, Selection methods, Object name, Preferences, Workbenches, Document structure, Properties, Help FreeCAD, Donate
- Help: Tutorials, Video tutorials
- Workbenches: Std Base, Arch, Assembly, CAM, Draft, FEM, Inspection, Mesh, OpenSCAD, Part, PartDesign, Points, Reverse Engineering, Robot, Sketcher, Spreadsheet, Start, Surface, TechDraw, Test Framework, Web
- Hubs: User hub, Power users hub, Developer hub