[Bf-extensions-cvs] [1cb218c3] master: xedit: code cleanup

NBurn noreply at git.blender.org
Fri May 31 10:46:40 CEST 2019


Commit: 1cb218c3a490b288cba036f5fdbbdc3c541751b8
Author: NBurn
Date:   Fri May 31 04:45:32 2019 -0400
Branches: master
https://developer.blender.org/rBAC1cb218c3a490b288cba036f5fdbbdc3c541751b8

xedit: code cleanup

===================================================================

M	exact_edit/xedit_free_rotate.py
M	exact_edit/xedit_set_meas.py

===================================================================

diff --git a/exact_edit/xedit_free_rotate.py b/exact_edit/xedit_free_rotate.py
index 757deb79..1acc490a 100644
--- a/exact_edit/xedit_free_rotate.py
+++ b/exact_edit/xedit_free_rotate.py
@@ -909,9 +909,7 @@ def create_z_orient(rot_vec):
             flt_lists_alm_eq(rot_vec, z_dir_p):
         return Matrix((x_dir_p, y_dir_p, z_dir_p))  # 3x3 identity
     new_z = rot_vec.copy()  # rot_vec already normalized
-    guide = z_dir_p
-    new_y = new_z.cross(guide)
-    tmp = Vector()
+    new_y = new_z.cross(z_dir_p)
     if flt_lists_alm_eq(new_y, (0.0, 0.0, 0.0)):
         new_y = y_dir_p
     new_x = new_y.cross(new_z)
diff --git a/exact_edit/xedit_set_meas.py b/exact_edit/xedit_set_meas.py
index 77efa99d..46d8c4b7 100644
--- a/exact_edit/xedit_set_meas.py
+++ b/exact_edit/xedit_set_meas.py
@@ -1247,9 +1247,7 @@ def create_z_orient(rot_vec):
             flt_lists_alm_eq(rot_vec, z_dir_p):
         return Matrix((x_dir_p, y_dir_p, z_dir_p))  # 3x3 identity
     new_z = rot_vec.copy()  # rot_vec already normalized
-    guide = z_dir_p
-    new_y = new_z.cross(guide)
-    tmp = Vector()
+    new_y = new_z.cross(z_dir_p)
     if flt_lists_alm_eq(new_y, (0.0, 0.0, 0.0)):
         new_y = y_dir_p
     new_x = new_y.cross(new_z)



More information about the Bf-extensions-cvs mailing list