]> git.tdb.fi Git - libs/gl.git/commitdiff
Fix multiplication operators in camera exporter
authorMikko Rasa <tdb@tdb.fi>
Thu, 15 Apr 2021 17:23:08 +0000 (20:23 +0300)
committerMikko Rasa <tdb@tdb.fi>
Thu, 15 Apr 2021 21:31:36 +0000 (00:31 +0300)
blender/io_mspgl/export_camera.py

index 02fce103c7f13d1f7fdc7e9fd934bd512c2f9031..984ec0dafa8ecd3fde4d6859abf5cf1f6241c4ef 100644 (file)
@@ -9,9 +9,9 @@ class CameraExporter:
                from .datafile import Resource, Statement
                resource = Resource(obj.name+".camera", "camera")
 
-               position = obj.matrix_world*mathutils.Vector((0, 0, 0))
+               position = obj.matrix_world@mathutils.Vector((0, 0, 0))
                resource.statements.append(Statement("position", position[0], position[1], position[2]))
-               look_dir = obj.matrix_world*mathutils.Vector((0, 0, -1, 0))
+               look_dir = obj.matrix_world@mathutils.Vector((0, 0, -1, 0))
                resource.statements.append(Statement("look_direction", look_dir[0], look_dir[1], look_dir[2]))
                resource.statements.append(Statement("up_direction", 0.0, 0.0, 1.0))
                resource.statements.append(Statement("field_of_view", obj.data.angle_y*180/math.pi))