Mesh Scale/ru: Difference between revisions

From FreeCAD Documentation
No edit summary
(Updating to match new version of source page)
 
(8 intermediate revisions by 3 users not shown)
Line 1: Line 1:
<languages/>
<languages/>

{{Docnav/ru
{{Docnav/ru
|[[Mesh Smooth/ru|Smooth...]]
|[[Mesh_Decimating/ru|Decimating]]
|[[Mesh_BuildRegularSolid/ru|BuildRegularSolid]]
|[[Mesh EvaluateRepair/ru|Evaluate & Repair mesh...]]
|[[Mesh_Workbench/ru|Mesh]]
|[[Mesh_Workbench/ru|Mesh]]
|IconL=Mesh_Smooth.png
|IconL=Mesh_Decimating.svg
|IconR=Mesh_BuildRegularSolid.svg
|IconC=Workbench_Mesh.svg
|IconC=Workbench_Mesh.svg
|IconR=Mesh_EvaluateRepair.png
}}
}}


<div class="mw-translate-fuzzy">
{{GuiCommand/ru
{{GuiCommand/ru
|Name=Mesh Scale
|Name=Mesh Scale
Line 17: Line 19:
|SeeAlso=
|SeeAlso=
}}
}}
</div>


<span id="Description"></span>
==Описание==
==Описание==


The '''Mesh Scale''' command scales mesh objects.
==Использование==


<span id="Usage"></span>
==Ограничения==
==Применение==

# Select one or more mesh objects.
# There are several ways to invoke the command:
#* Press the {{Button|[[Image:Mesh_Scale.svg|16px]] [[Mesh_Scale|Scale...]]}} button.
#* Select the {{MenuCommand|Meshes → [[Image:Mesh_Scale.svg|16px]] Scale...}} option from the menu.
# The {{MenuCommand|Scaling}} dialog box opens.
# Specify a scaling factor, the value must be larger than {{Value|0}}.
# Press the {{button|OK}} button to finish the command.

==Scripting==

See also: [[FreeCAD_Scripting_Basics|FreeCAD Scripting Basics]].

To scale a mesh use its {{incode|transformGeometry}} method.

{{Code|code=
import FreeCAD as App
import Mesh

# Create a non-parametric box-shaped mesh:
msh = App.ActiveDocument.addObject("Mesh::Feature", "Mesh")
msh.Mesh = Mesh.createBox(10, 10, 10)
msh.ViewObject.DisplayMode = "Flat Lines"

# Create and scale a matrix:
mat = App.Matrix()
mat.scale(2.0, 3.0, 4.0) # Unequal scaling.

# We need to work on a copy of the msh.Mesh object:
new_msh = msh.Mesh.copy()

# Transform that copy:
new_msh.transformGeometry(mat)

# Update msh.Mesh:
msh.Mesh = new_msh
}}


==Примечания==


{{Docnav/ru
{{Docnav/ru
|[[Mesh Smooth/ru|Smooth...]]
|[[Mesh_Decimating/ru|Decimating]]
|[[Mesh_BuildRegularSolid/ru|BuildRegularSolid]]
|[[Mesh EvaluateRepair/ru|Evaluate & Repair mesh...]]
|[[Mesh_Workbench/ru|Mesh]]
|[[Mesh_Workbench/ru|Mesh]]
|IconL=Mesh_Smooth.png
|IconL=Mesh_Decimating.svg
|IconR=Mesh_BuildRegularSolid.svg
|IconC=Workbench_Mesh.svg
|IconC=Workbench_Mesh.svg
|IconR=Mesh_EvaluateRepair.png
}}
}}



Latest revision as of 13:15, 26 November 2023

Other languages:

Mesh Scale

Системное название
Mesh Scale
Расположение в меню
Нет
Верстаки
Mesh
Быстрые клавиши
Нет
Представлено в версии
-
См. также
Нет

Описание

The Mesh Scale command scales mesh objects.

Применение

  1. Select one or more mesh objects.
  2. There are several ways to invoke the command:
    • Press the Scale... button.
    • Select the Meshes → Scale... option from the menu.
  3. The Scaling dialog box opens.
  4. Specify a scaling factor, the value must be larger than 0.
  5. Press the OK button to finish the command.

Scripting

See also: FreeCAD Scripting Basics.

To scale a mesh use its transformGeometry method.

import FreeCAD as App
import Mesh

# Create a non-parametric box-shaped mesh:
msh = App.ActiveDocument.addObject("Mesh::Feature", "Mesh")
msh.Mesh = Mesh.createBox(10, 10, 10)
msh.ViewObject.DisplayMode = "Flat Lines"

# Create and scale a matrix:
mat = App.Matrix()
mat.scale(2.0, 3.0, 4.0) # Unequal scaling.

# We need to work on a copy of the msh.Mesh object:
new_msh = msh.Mesh.copy()

# Transform that copy:
new_msh.transformGeometry(mat)

# Update msh.Mesh:
msh.Mesh = new_msh