From fc9fa07c0e177bda4c5ae2233616081ed48f2c8c Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Mon, 14 Nov 2016 04:10:47 +1100 Subject: BMesh: BM_face_exists no longer uses return arg Just return the face or NULL, like BM_edge_exists(), Also for BM_face_exists_overlap & bm_face_exists_tri_from_loop_vert. No functional changes. Old code did some partial overlap checks where this made some sense, but it's since been removed. --- source/blender/python/bmesh/bmesh_py_types.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source/blender/python') diff --git a/source/blender/python/bmesh/bmesh_py_types.c b/source/blender/python/bmesh/bmesh_py_types.c index 1d951bae48b..b20c03bee28 100644 --- a/source/blender/python/bmesh/bmesh_py_types.c +++ b/source/blender/python/bmesh/bmesh_py_types.c @@ -2233,7 +2233,7 @@ static PyObject *bpy_bmfaceseq_new(BPy_BMElemSeq *self, PyObject *args) } /* check if the face exists */ - if (BM_face_exists(vert_array, vert_seq_len, NULL)) { + if (BM_face_exists(vert_array, vert_seq_len) != NULL) { PyErr_SetString(PyExc_ValueError, "faces.new(verts): face already exists"); goto cleanup; @@ -2426,7 +2426,8 @@ static PyObject *bpy_bmfaceseq_get__method(BPy_BMElemSeq *self, PyObject *args) return NULL; } - if (BM_face_exists(vert_array, vert_seq_len, &f)) { + f = BM_face_exists(vert_array, vert_seq_len); + if (f != NULL) { ret = BPy_BMFace_CreatePyObject(bm, f); } else { -- cgit v1.2.3