Arch SplitMesh/ru: Difference between revisions

From FreeCAD Documentation
No edit summary
(Updating to match new version of source page)
Line 2: Line 2:


{{Docnav
{{Docnav
|[[Arch_CloneComponent|Clone component]]
|[[Arch_CloneComponent|Clonecomponent]]
|[[Arch_MeshToShape|Mesh To Shape]]
|[[Arch_MeshToShape|MeshToShape]]
|[[Arch_Workbench|Arch]]
|[[Arch_Workbench|Arch]]
|IconL=Arch_CloneComponent.svg
|IconL=Arch_CloneComponent.svg
Line 64: Line 64:
new_list = Arch.splitMesh(mesh_obj)
new_list = Arch.splitMesh(mesh_obj)
}}
}}



{{Docnav
{{Docnav
|[[Arch_CloneComponent|Clone component]]
|[[Arch_CloneComponent|Clonecomponent]]
|[[Arch_MeshToShape|Mesh To Shape]]
|[[Arch_MeshToShape|MeshToShape]]
|[[Arch_Workbench|Arch]]
|[[Arch_Workbench|Arch]]
|IconL=Arch_CloneComponent.svg
|IconL=Arch_CloneComponent.svg
Line 75: Line 76:


{{Arch Tools navi{{#translation:}}}}
{{Arch Tools navi{{#translation:}}}}

{{Userdocnavi{{#translation:}}}}
{{Userdocnavi{{#translation:}}}}

Revision as of 15:05, 9 March 2022

Arch SplitMesh

Системное название
Arch SplitMesh
Расположение в меню
Архитектура → Утилиты → Разделить сетку
Верстаки
Arch
Быстрые клавиши
Нет
Представлено в версии
-
См. также
Выбрать не-разнородные сетки

Описание

Этот инструмент разбивает выбранную сетку на отдельные компоненты

Использование

  1. Select a mesh object.
  2. Press the Split Mesh entry in Arch → Utilities → Split Mesh.

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)