MCPcopy
hub / github.com/CadQuery/cadquery / translate

Method translate

cadquery/occ_impl/shapes.py:1154–1162  ·  view source on GitHub ↗

Translates this shape through a transformation.

(self: T, vector: VectorLike)

Source from the content-addressed store, hash-verified

1152 return self._apply_transform(Tr)
1153
1154 def translate(self: T, vector: VectorLike) -> T:
1155 """
1156 Translates this shape through a transformation.
1157 """
1158
1159 T = gp_Trsf()
1160 T.SetTranslation(Vector(vector).wrapped)
1161
1162 return self._apply_transform(T)
1163
1164 def scale(self, factor: float) -> Shape:
1165 """

Callers

nothing calls this directly

Calls 2

_apply_transformMethod · 0.95
VectorClass · 0.85

Tested by

no test coverage detected