Part Offset2D/pl: Difference between revisions

From FreeCAD Documentation
(Created page with "==Właściwości==")
(Created page with "* {{PropertyData|Źródło}}: Łącze do oryginalnego kształtu")
Line 63: Line 63:
==Właściwości==
==Właściwości==


* {{PropertyData|Source}}: Link to original shape
* {{PropertyData|Źródło}}: Łącze do oryginalnego kształtu


* {{PropertyData|Value}}: The distance to enlarge the wire/face by. If negative, the wire/face is shrunk instead.
* {{PropertyData|Value}}: The distance to enlarge the wire/face by. If negative, the wire/face is shrunk instead.

Revision as of 13:27, 30 June 2023

Część: Odsunięcie 2D

Lokalizacja w menu
Część → Odsunięcie 2D
Środowisko pracy
Część
Domyślny skrót
brak
Wprowadzono w wersji
0.17
Zobacz także
Odsunięcie 3D, Grubość, Odsunięcie

Opis

Narzędzie Offset 2D tworzy polilinię równoległą do oryginalnej polilinii w pewnej odległości od niej. Lub powiększa/zmniejsza płaską ścianę, w podobny sposób.

Polilinia / ściana musi być płaska. W jednym obiekcie może znajdować się wiele przewodów, niekoniecznie współpłaszczyznowych.

Użycie

  1. Wybierz obiekt do przesunięcia.
  2. Naciśnij przycisk Odsunięcie 2D.
  3. Ustaw przesunięcie w oknie Panelu zadań.
  4. Naciśnij OK.

Uwagi

Znane problemy

  • Większość trybów innych niż domyślne będzie działać tylko z OCC 7.0.0 lub nowszym.
  • Korzystanie z narzędzia może spowodować awarię FreeCAD (patrz następny punkt). W systemie Windows awarie te są konwertowane na wyjątki i generalnie nie powodują zamknięcia FreeCAD. W innych systemach operacyjnych tak nie jest, dlatego zaleca się zapisanie projektu przed próbą użycia narzędzia. Nie są również obsługiwane elipsy.
  • Powiększanie ścian z okrągłymi otworami o ilość wystarczającą do zamknięcia otworów powoduje awarię (OCC 7.0.0). Problem wydaje się być specyficzny dla okręgów; inne kształty wydają się zamykać prawidłowo.
  • Podczas kompensowania okręgów, które mają niezerowe Umiejscowienie, wynik jest umieszczany nieprawidłowo. (OCC 7.0.0)
  • Podczas przesuwania okręgów czasami są one przesuwane w nieoczekiwanym kierunku (np. do wewnątrz zamiast na zewnątrz). (OCC 7.0.0)
  • Wypełnienie - wartość Prawda nie działa podczas zbiorczego odsunięcia otwartych polilinii w trybie "Powłoka".
  • Tryb łączenia "styczny" nie działa (OCC 7.0.0).
  • Odsunięcie polilinii wykonanej z pojedynczego segmentu linii nie jest obsługiwane (ponieważ segment linii nie definiuje płaszczyzny). Pojedyncze segmenty linii również nie mogą uczestniczyć w przesunięciu zbiorowym.

Właściwości

  • DANEŹródło: Łącze do oryginalnego kształtu
  • DANEValue: The distance to enlarge the wire/face by. If negative, the wire/face is shrunk instead.
  • DANEMode ("Pipe" or "Skin"): sets how non-closed wires are processed. If "Pipe", the wire is outlined as if it was an extremely thin closed contour. If "Skin", an open wire is created.
  • DANEJoin ("Arc", "Tangent", "Intersection"): sets the behavior around kinks. If "Arc", offset segments are connected with an arc of circle, centered at the vertex. "Tangent" is unsupported on OCC7.0.0. "Intersection": offset segments are extended till they intersect.
  • DANEIntersection ("false", "true"): sets if multiple wires are treated collectively or independently. If "false", wires are offset independently, intersections between resulting wires are ignored. If "true", the wires are offset in collective manner.
Only wires within a compound are coupled. For example, if the structure is like compound(wire1, wire2, compound(wire3, wire4)), wire1 and wire2 will be treated collectively, but independently from wire3 and wire4. Likewise, wire3 and wire4 are treated collectively, but independently of wire1+wire2.
Also, in collective mode, directions of wires are important, and influence direction of offset. This is in tight relationship with how holes in faces are treated.
Wires being treated collectively must be coplanar. Wires being offset independently don't have to be coplanar.
  • DANEFill ("false", "true"): if "true", the space between original wire/face and the offset is filled with a face.

Tworzenie skryptów

Narzędzie Odsunięcie 2D może być używane w makrodefinicjach i z konsoli Python za pomocą następującej funkcji:

f = App.ActiveDocument.addObject("Part::Offset2D", "Offset2D")
f.Source =  #some object
f.Value = 10.0

Odsunięcie 2D jest również dostępne jako metoda Part.Shape. Przykład:

import Part
circle = Part.Circle().toShape()
enlarged_circle = circle.makeOffset2D(10.0)
Part.show(circle)
Part.show(enlarged_circle)
# makeOffset2D(offset, join = 0, fill = False, openResult = false, intersection = false)
# 
# * offset: distance to expand the shape by. 
# 
# * join: method of offsetting non-tangent joints. 0 = arcs, 1 = tangent, 2 =
# intersection
# 
# * fill: if true, the output is a face filling the space covered by offset. If
# false, the output is a wire/face.
# 
# * openResult: True for "Skin" mode; False for Pipe mode. 
# 
# * intersection: collective offset
# 
# Returns: result of offsetting (wire or face or compound of those). Compounding
# structure follows that of source shape.