To produce a Translation in the Main Menu select Operations - > Transformation - > Translation
This Operation makes a translation of an Object. To translate a shape you need to define the base shape and the coordinates of the vector of translation. Create a copy checkbox allows to keep the initial object, otherwise it will be removed.
The Result of all operations will be any GEOM_Object.
Firstly you can define an Object and the vector coordinates along the axes.
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: Name + one or several objects + 3 values (coordinates).
Advanced option: Set presentation parameters and sub-shapes from arguments.
Secondly you can define an Object and the start and the end points of the vector.
TUI Command: geompy.MakeTranslationTwoPoints(Object, Point1, Point2)
Arguments: Name + one or several objects + 2 vertices
Advanced option: Set presentation parameters and sub-shapes from arguments.
Finally you can define an Object and a vector. The object will be translated by the length of the vector. If a curve has been selected instead of the vector, only its first and last vertices will be used to get the vector direction and the dialog preview will display the vector along which the object will be translated.
TUI Command: geompy.MakeTranslationVector(Object, Vector)
Activate Distance checkbox and Distance field allow defining the custom distance of translation.
TUI Command for translation by vector and custom distance: geompy.MakeTranslationVectorDistance(Object, Vector, Distance)
Arguments: Name + one or several objects + 1 vector.
Advanced option: Set presentation parameters and sub-shapes from arguments.
Example:
Our TUI Scripts provide you with useful examples of the use of Transformation Operations.