diff options
author | Campbell Barton <ideasman42@gmail.com> | 2009-08-26 10:15:43 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2009-08-26 10:15:43 +0400 |
commit | 43422354895bb620d6731f928d121ae6cd06da48 (patch) | |
tree | 6eb4a4191a804bc4433f72ac03ae0417aca0c1bd /source/blender/python/generic | |
parent | d893b0f9ff5fc21277b9c24568e224961537c23c (diff) |
- Mathutils.Vector assignment wasnt working in the BGE's py api, was using getValue() rather than setValue()
- added GPL header to bpy_interface.c from 2.4x's BPY_interface.c
- warning fixes
Diffstat (limited to 'source/blender/python/generic')
-rw-r--r-- | source/blender/python/generic/bpy_internal_import.h | 9 | ||||
-rw-r--r-- | source/blender/python/generic/vector.c | 4 |
2 files changed, 11 insertions, 2 deletions
diff --git a/source/blender/python/generic/bpy_internal_import.h b/source/blender/python/generic/bpy_internal_import.h index c93d930dab0..4e761fe8da0 100644 --- a/source/blender/python/generic/bpy_internal_import.h +++ b/source/blender/python/generic/bpy_internal_import.h @@ -31,6 +31,15 @@ #ifndef EXPP_bpy_import_h #define EXPP_bpy_import_h +/* python redefines :/ */ +#ifdef _POSIX_C_SOURCE +#undef _POSIX_C_SOURCE +#endif + +#ifdef _XOPEN_SOURCE +#undef _XOPEN_SOURCE +#endif + #include <Python.h> #include "compile.h" /* for the PyCodeObject */ #include "eval.h" /* for PyEval_EvalCode */ diff --git a/source/blender/python/generic/vector.c b/source/blender/python/generic/vector.c index 923c4bbe58a..c4a8a37ee05 100644 --- a/source/blender/python/generic/vector.c +++ b/source/blender/python/generic/vector.c @@ -168,7 +168,7 @@ static PyObject *Vector_Resize2D(VectorObject * self) return NULL; } if(self->cb_user) { - PyErr_SetString(PyExc_TypeError, "vector.resize4d(): cannot resize a vector that has an owner"); + PyErr_SetString(PyExc_TypeError, "vector.resize2d(): cannot resize a vector that has an owner"); return NULL; } @@ -191,7 +191,7 @@ static PyObject *Vector_Resize3D(VectorObject * self) return NULL; } if(self->cb_user) { - PyErr_SetString(PyExc_TypeError, "vector.resize4d(): cannot resize a vector that has an owner"); + PyErr_SetString(PyExc_TypeError, "vector.resize3d(): cannot resize a vector that has an owner"); return NULL; } |