Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rotation: - Add a private attribute Vector to store the direction of the rotation, and manage not to erase this direction when the angle id 0. - Add a private attribute to store the angle as defined (no modulo etc) - Keep the quaternion for calculations PropertyGeo - Saves the rotation with angle and direction instead of saving the quaternion. - Attribute name chosen: Ox, Oy and Oz for the coordinates of the axis and A for the angle in radians. This has to be validated. - Backward compatibility with the saved files with quaternion (test presence of A to determine which of the Quaternion (old way) or the direction and angle is stored (new way). New files can be opened by old FreeCAD and vice-versa. The only side effect I can imagine is that it was possible to set a vector to 0, 0, 0 if the angle was not 0, what is somehow non sense. Now when setting to 0, 0 0 the last not null vector is kept. The vector can not be null any longer.
- Loading branch information
Showing
3 changed files
with
120 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters