# Titre

# Using transformation operations

In GEOM there is a set of operations allowing to transform the initial geometrical object into other objects, which will be also created. These operations are

- Translation

- Rotation

- Modify the location

- Mirror image

- Scale transform

- Offset surface

- Multi-Translation (Pattern)

- Multi-Rotation (Pattern)

All these operations are accessible in the main menu, via Operations / Transformation.

Translation

Description: Makes a translation of a shape.

Result: GEOM_Object.

TUI Command: geompy.MakeTranslation(Shape, DX, DY, DZ), where Shape is a shape to be translated, DX, DY, DZ are components of translation vector.

Arguments:

- 1st Constructor: Name + 1 shape + 3 values (coordinates).

- 2st Constructor: Name + 1 shape + 2 vertices.

- 3st Constructor: Name + 1 shape + 1 vector.

Create a copy checkbox allows to keep the initial object, otherwise it will be removed.

Dialog Box:

Example:

Rotation

Description: Rotates the initial shape.

Result: GEOM_Object.

TUI Command: geompy.MakeRotation(Shape, Axis, Angle), where Shape is a shape to be rotated, Axis is an axis of rotation, Angle is an angle of rotation.

Arguments: 1 shape + 1 vector for direction of rotation + 1 angle.

Reverse checkbox allows to specify the direction of rotation.

Create a copy checkbox allows to keep the initial object, otherwise it will be removed.

Dialog Box:

Example:

Modify the Location

Description: Modification of location of an object.

Result: GEOM_Object.

TUI Command: geompy.MakePosition(theObject, theStartLCS, theEndLCS), where theObject is a shape, location of which is modified, theStartLCS is a location to move the shape from, theEndLCS is a location to move the shape to.

Arguments: Name + 1 GEOM_Object + [Starting Coordinate System] + End Coordinate System.

Create a copy checkbox allows to keep the initial object, otherwise it will be removed.

Dialog Box:

Example:

Mirror

Description: Symmetrical copy of a shape.

Result: GEOM_Object.

TUI Command: geompy.MakeMirrorByPlane(Shape, Plane), where Shape is a shape to be mirrored, Plane is a plane of symmetry.

Arguments:

- 1st Constructor: Name + 1 shape + 1 vertex.

- 2st Constructor: Name + 1 shape + 1 vector.

- 3st Constructor: Name + 1 shape + 1 plane.

Create a copy checkbox allows to keep the initial object, otherwise it will be removed.

Dialog Box:

Example:

Scale transform

Description: Creates a scaled shape basing on the initial shape.

Result: GEOM_Object.

TUI Command: geompy.MakeScaleTransform(Shape, CenterOfScale, Factor), where Shape is a shape to be scaled, CenterOfScale is a center point of scale, Factor is a factor of the scale.

Arguments: Name + 1 shape(s) + 1 vertex + 1 Scale Factor.

Dialog Box:

Example:

Offset surface

Description: Each point is translated along a local normal by a given distance (signed number, negative value meaning inner offset). Offset operation is applicable to faces, shells and solids.

Result: GEOM_Object

TUI Command: geompy.MakeOffset(Shape, Offset), where Shape is a shape which has to be an offset, Offset is a value of the offset.

Arguments:

- Name of the resulting object

- GEOM_Object (face, shell, solid, compound)

- offset value

Dialog Box:

Example:

Multi-Translation

Description: Makes several translations of a shape in one or two directions.

Result: GEOM_Object (compound).

TUI Command:

- geompy.MakeMultiTranslation1D(Shape, Dir, Step, NbTimes), where Shape is a shape to be translated, Dir is a direction of translation, Step is a step of the translation, NbTimes is a number of times the shape must be moved.

- geompy.MakeMultiTranslation2D(Shape, Dir1, Step1, NbTimes1, Dir2, Step2, NbTimes2), where Shape is a shape to be translated, Dir1 is the first direction of translation, Step1 of the first translation, NbTimes1 is a number of translations to be done along, Dir2 is the second direction of translation, Step2 of the second translation, NbTimes2 is a number of translations to be done along Dir2.

Arguments:

- 1st Constructor (in one direction): Name + 1 shape + 1 vector (for direction) + 1 step value + 1 value (repetition).

- 2nd Constructor (in two directions): Name + 1 shape + 2 vectors defining the direction + 2 step values + 2 values (repetitions).

Dialog Box:

Example:

One direction:

Two directions:

Multi-Rotation

Description: Creates several rotated geometrical objects in one or two directions basing on the initial geometrical object.

Result: GEOM_Object (compound).

TUI Command:

- geompy.MakeMultiRotation1D(Shape, Axis, NbTimes), where Shape is a shape to be rotated, Axis is an Axis of rotation, NbTimes is a number of the shape must be rotated.

- geompy.MakeMultiRotation2D(Shape, Axis, Angle, NbTimes1, Step, NbTimes2), where Shape is a shape to be rotated, Axis is an axis of rotation, Angle is an angle of rotation, NbTimes1 is a number of rotation, Step is a step of translation, NbTimes2 is a number of translation.

Arguments:

- 1st Constructor (in one direction): Name + 1 shape + 1 vector for direction + 1 value (repetition).

- 2nd Constructor (in two directions): Name + 1 shape + 1 vector for direction + 1 angle + 1 value (repetition) + 1 step value + 1 value (repetition); Reverse checkbox allows to set the direction of rotation.

Dialog Box:

Example:

One direction:

Two directions: