A computer-implemented method for generating a movement of a given three-dimensional (3D) part of a 3D assembly of 3D parts in a 3D scene, the movement of the given 3D part comprising at least a rotation at most by a predetermined angle, the method comprising the steps of:
- a) displaying the 3D assembly of 3D parts in the 3D scene;
- b) selecting the given 3D part of the 3D assembly of 3D parts;
- c) displaying in the 3D scene a 3D manipulator comprising three axes, said 3D manipulator being anchored to the given 3D part in an anchor point;
- d) dragging the 3D manipulator along one axis of the three axes by a current distance from the anchor point on said one axis, the predetermined angle corresponding to a maximum distance from the anchor point;
- and
- e) responsive to the dragging the 3D manipulator:
- e1) computing a ratio of the current distance to the maximum distance, and
- e2) generating the movement of the given 3D part proportionally to the ratio, such that the movement comprising at least a rotation at most by the predetermined angle stops if the 3D manipulator is dragged beyond the maximum distance;
- wherein the movement further comprises a translation, without rotation, by a predetermined length along said one axis, the method further comprising:
- (i) in step d), splitting the maximum distance (MD) into two partial maximum distances (MD1, MD2), the predetermined angle corresponding to a first partial maximum distance (MD1) of the two partial maximum distances (MD1, MD2), the predetermined length corresponding to a second partial maximum distance (MD2) of the two partial maximum distances (MD1, MD2);
- (ii) in step e1), computing a first ratio of the current distance (CD) to the first partial maximum distance (MD1), determining an intermediate point located on said one axis, away from the anchor point (ANP) by the first partial maximum distance (MD1), recomputing the current distance (CD) starting from the intermediate point and computing a second ratio of the recomputed current distance (CD) to the second partial maximum distance (MD2);
- and
- (iii) in step e2), generating the rotation of the given 3D part proportionally to the first ratio and the translation of the given 3D part proportionally to the second ratio.