Arch SplitMesh/pl: Difference between revisions

From FreeCAD Documentation
(Created page with "==Użycie==")
(Created page with "# Wybierz obiekt siatki. # Naciśnij przycisk {{Button|16px '''Podziel siatkę'''}} w {{MenuCommand|Architektura → Narzędzia → Podziel siatkę}}.")
Line 26: Line 26:
==Użycie==
==Użycie==


# Wybierz obiekt siatki.
# Select a mesh object.
# Press the {{Button|[[Image:Arch_SplitMesh.svg|16px]] [[Arch_SplitMesh|Split Mesh]]}} entry in {{MenuCommand|ArchUtilitiesSplit Mesh}}.
# Naciśnij przycisk {{Button|[[Image:Arch_SplitMesh.svg|16px]] '''Podziel siatkę'''}} w {{MenuCommand|ArchitekturaNarzędziaPodziel siatkę}}.


==Scripting==
==Scripting==

Revision as of 14:19, 6 May 2024

Architektura: Podziel siatkę

Lokalizacja w menu
Architektura → Narzędzia → Podziel siatkę
Środowisko pracy
Architektura
Domyślny skrót
brak
Wprowadzono w wersji
-
Zobacz także
Zaznacz siatki niebryłowe, Siatka na kształt

Opis

Narzędzie to dzieli wybrany obiekt Siatki na jego oddzielne komponenty.

Użycie

  1. Wybierz obiekt siatki.
  2. Naciśnij przycisk Podziel siatkę w Architektura → Narzędzia → Podziel siatkę.

Scripting

See also: Arch API and FreeCAD Scripting Basics.

The SplitMesh tool can be used in macros and from the Python console by using the following function:

new_list = splitMesh(obj, mark=True)
  • Splits the given mesh object (obj) into separated components.
  • If mark is True non-manifold components will be painted red.
  • new_list is a list of all the individual components that make the mesh.

Example:

import FreeCAD, Draft, Arch, Mesh, MeshPart

Line = Draft.makeWire([FreeCAD.Vector(0, 0, 0),FreeCAD.Vector(2000, 2000, 0)])
Wall = Arch.makeWall(Line, width=150, height=3000)
FreeCAD.ActiveDocument.recompute()

Shape = Wall.Shape.copy(False)
Shape.Placement = Wall.getGlobalPlacement()

mesh_obj = FreeCAD.ActiveDocument.addObject("Mesh::Feature", "Mesh")
mesh_obj.Mesh = MeshPart.meshFromShape(Shape=Shape, MaxLength=520)
mesh_obj.ViewObject.DisplayMode = "Flat Lines"

new_list = Arch.splitMesh(mesh_obj)