Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKen Hughes <khughes@pacific.edu>2005-12-05 22:57:23 +0300
committerKen Hughes <khughes@pacific.edu>2005-12-05 22:57:23 +0300
commit1a2ac4e64d6a8dfc1810d35bfc4c8fd7acbc37fe (patch)
tree9a7efbea6cd6b495167a2b2e62694d14100627a2 /source/blender/python/api2_2x/matrix.c
parente209676d3d55c3d6a4e2fffd97cbd448a7bb556b (diff)
-- Bugfix #3072: As discussed on IRC, matrix.invert() should throw a
ValueError exception if matrix is singular.
Diffstat (limited to 'source/blender/python/api2_2x/matrix.c')
-rw-r--r--source/blender/python/api2_2x/matrix.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/python/api2_2x/matrix.c b/source/blender/python/api2_2x/matrix.c
index 894643c5362..d1e6a53bae5 100644
--- a/source/blender/python/api2_2x/matrix.c
+++ b/source/blender/python/api2_2x/matrix.c
@@ -228,7 +228,8 @@ PyObject *Matrix_Invert(MatrixObject * self)
//transpose
//Matrix_Transpose(self);
} else {
- printf("Matrix.invert: matrix does not have an inverse\n");
+ return EXPP_ReturnPyObjError(PyExc_ValueError,
+ "matrix does not have an inverse");
}
return EXPP_incr_ret((PyObject*)self);
}