forked from bartvdbraak/blender
parent
ffcec4024b
commit
148ccc2f17
@ -1,15 +1,15 @@
|
||||
import mathutils
|
||||
|
||||
# zero length vector
|
||||
vec = mathutils.Vector(0, 0, 1)
|
||||
vec = mathutils.Vector((0, 0, 1))
|
||||
|
||||
# unit length vector
|
||||
vec_a = vec.copy().normalize()
|
||||
|
||||
vec_b = mathutils.Vector(0, 1, 2)
|
||||
vec_b = mathutils.Vector((0, 1, 2))
|
||||
|
||||
vec2d = mathutils.Vector(1, 2)
|
||||
vec3d = mathutils.Vector([1, 0, 0])
|
||||
vec2d = mathutils.Vector((1, 2))
|
||||
vec3d = mathutils.Vector((1, 0, 0))
|
||||
vec4d = vec_a.copy().resize4D()
|
||||
|
||||
# other mathutuls types
|
||||
|
@ -1,7 +1,7 @@
|
||||
import mathutils
|
||||
from math import radians
|
||||
|
||||
vec = mathutils.Vector(1.0, 2.0, 3.0)
|
||||
vec = mathutils.Vector((1.0, 2.0, 3.0))
|
||||
|
||||
mat_rot = mathutils.RotationMatrix(radians(90), 4, 'X')
|
||||
mat_trans = mathutils.TranslationMatrix(vec)
|
||||
|
Loading…
Reference in New Issue
Block a user