diff options
Diffstat (limited to 'source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp')
-rw-r--r-- | source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp b/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp index 24c0263bc5f..541ef4f4516 100644 --- a/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp +++ b/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp @@ -395,17 +395,19 @@ PyObject * StrokeAttribute_setThickness( BPy_StrokeAttribute *self, PyObject *ar } PyObject * StrokeAttribute_setVisible( BPy_StrokeAttribute *self, PyObject *args ) { - int i = 0; + PyObject *py_b; - if(!( PyArg_ParseTuple(args, "i", &i) )) { + if(!( PyArg_ParseTuple(args, "O", &py_b) && PyBool_Check(py_b) )) { cout << "ERROR: StrokeAttribute_setVisible" << endl; Py_RETURN_NONE; } - self->sa->setVisible( i ); + self->sa->setVisible( bool_from_PyBool(py_b) ); + Py_RETURN_NONE; } + PyObject * StrokeAttribute_setAttributeReal( BPy_StrokeAttribute *self, PyObject *args ) { char *s = 0; double d = 0; |