Powierzchnia 3D: Przekrój powierzchni

From FreeCAD Documentation
Revision as of 17:05, 24 January 2024 by Kaktus (talk | contribs) (Created page with "==Opcje==")
Other languages:

Powierzchnia 3D: Przekrój powierzchni

Lokalizacja w menu
Surface → Sections
Środowisko pracy
Powierzchnia 3D
Domyślny skrót
brak
Wprowadzono w wersji
0.19
Zobacz także
brak

Opis

Polecenie Przekrój powierzchni służy do tworzenia powierzchni z krawędzi, które reprezentują poprzeczne przekroje powierzchni.

Po lewej: krawędzie kontrolne (przekroje poprzeczne). Po prawej: powierzchnia utworzona z tych krawędzi.

Użycie

  1. Upewnij się, że masz co najmniej dwie krawędzie lub krzywe w przestrzeni. Na przykład można je utworzyć za pomocą narzędzi środowiska pracy Rysunek Roboczy lub Szkicownik.
  2. Naciśnij przycisk Przekrój powierzchni.
  3. Naciśnij Template:Przycisk.
  4. Użyj kursora, aby wybrać żądane krawędzie w oknie widoku 3D; podgląd ostatecznego kształtu zostanie wyświetlony po wybraniu dwóch prawidłowych krawędzi.
  5. Naciśnij OK, aby zakończyć operację.

Opcje

  • Add edge: press once to start picking edges in the 3D view. Individual lines such as Draft BSplines and Sketcher BSplines can be chosen, as well as any edge from solid objects, like those of PartDesign Bodies and Part Primitives.
  • Remove edge: press once to start picking edges in the 3D view; these must be edges that were previously picked with Add edge.
  • Right mouse button: open the context menu and select Remove, or press Del in the keyboard, to remove the currently selected edge in the list.
  • Drag: drag the currently selected element in the list in order to change the order in which it will be processed; the list is processed from top to bottom.
  • Press Cancel or Esc to abort the current operation.

Properties

A Surface Sections (Surface::Sections class) is derived from the basic Part Feature (Part::Feature class, through the Part::Spline subclass), therefore it shares all the latter's properties.

In addition to the properties described in Part Feature, the Surface Sections has the following properties in the property editor.

Data

Sections

  • DANENSections (LinkSubList): a list of edges that will be used to build the surface.

View

Base

  • WIDOKControl Points (Bool): it defaults to false; if set to true, it will show an overlay with the control points of the surface.

Twisting of the surface

The shape of the surface depends on the direction of the chosen edges; if edges are selected and the result is a surface that "twists" on itself, one of the edges may need its list of vertices in the reverse order. See the information in GeomFillSurface for a more complete explanation.

Scripting

See also: FreeCAD Scripting Basics.

The Surface Sections tool can be used in macros and from the Python console by adding the Surface::Sections object.

  • The edges to be used to define the surface must be assigned as a LinkSubList to the NSections property of the object.
  • All objects with edges need to be computed before they can be used as input for the properties of the Sections object.
import FreeCAD as App
import Draft

doc = App.newDocument()

pl1 = App.Placement()
obj1 = Draft.make_circle(50, placement=pl1, face=False, startangle=0, endangle=180)

pl2 = App.Placement(App.Vector(0, 0, 25), App.Rotation())
obj2 = Draft.make_circle(30, placement=pl2, face=False, startangle=0, endangle=180)

points3 = [App.Vector(18, -10, 50),
           App.Vector(12, 10, 50),
           App.Vector(-12, 10, 50),
           App.Vector(-18, -10, 50)]
obj3 = Draft.make_bspline(points3)

points4 = [App.Vector(15, -20, 100),
           App.Vector(0, 6, 100),
           App.Vector(-15, -20, 100)]
obj4 = Draft.make_bspline(points4)
doc.recompute()

surf = doc.addObject("Surface::Sections", "Surface")
surf.NSections = [(obj1, "Edge1"),
                  (obj2, "Edge1"),
                  (obj3, "Edge1"),
                  (obj4, "Edge1")]
doc.recompute()