Fix: BMesh Python API errors after vertex_normals addition

64cd927519 didn't update the argument parsing strings,
and updated the docstring of `from_object` incorrectly.

Fixes T97025, T97213
This commit is contained in:
2022-04-12 11:08:21 -05:00
parent 05a1770ab0
commit 77db370cb6

View File

@@ -1061,8 +1061,9 @@ PyDoc_STRVAR(bpy_bmesh_from_object_doc,
" :arg cage: Get the mesh as a deformed cage.\n" " :arg cage: Get the mesh as a deformed cage.\n"
" :type cage: boolean\n" " :type cage: boolean\n"
" :arg face_normals: Calculate face normals.\n" " :arg face_normals: Calculate face normals.\n"
" :type face_normals: boolean\n"
" :arg vertex_normals: Calculate vertex normals.\n" " :arg vertex_normals: Calculate vertex normals.\n"
" :type face_normals: boolean\n"); " :type vertex_normals: boolean\n");
static PyObject *bpy_bmesh_from_object(BPy_BMesh *self, PyObject *args, PyObject *kw) static PyObject *bpy_bmesh_from_object(BPy_BMesh *self, PyObject *args, PyObject *kw)
{ {
static const char *kwlist[] = { static const char *kwlist[] = {
@@ -1083,7 +1084,7 @@ static PyObject *bpy_bmesh_from_object(BPy_BMesh *self, PyObject *args, PyObject
if (!PyArg_ParseTupleAndKeywords(args, if (!PyArg_ParseTupleAndKeywords(args,
kw, kw,
"OO|$O&O&:from_object", "OO|$O&O&O&:from_object",
(char **)kwlist, (char **)kwlist,
&py_object, &py_object,
&py_depsgraph, &py_depsgraph,
@@ -1190,7 +1191,7 @@ static PyObject *bpy_bmesh_from_mesh(BPy_BMesh *self, PyObject *args, PyObject *
if (!PyArg_ParseTupleAndKeywords(args, if (!PyArg_ParseTupleAndKeywords(args,
kw, kw,
"O|$O&O&i:from_mesh", "O|$O&O&O&i:from_mesh",
(char **)kwlist, (char **)kwlist,
&py_mesh, &py_mesh,
PyC_ParseBool, PyC_ParseBool,