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:
Diffstat (limited to 'source/blender/python/gpu/gpu_py_element.c')
-rw-r--r--source/blender/python/gpu/gpu_py_element.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/source/blender/python/gpu/gpu_py_element.c b/source/blender/python/gpu/gpu_py_element.c
index 04975fcef96..d52a97c0c84 100644
--- a/source/blender/python/gpu/gpu_py_element.c
+++ b/source/blender/python/gpu/gpu_py_element.c
@@ -16,7 +16,6 @@
#include "MEM_guardedalloc.h"
#include "../generic/py_capi_utils.h"
-#include "../generic/python_utildefines.h"
#include "gpu_py.h"
#include "gpu_py_element.h" /* own include */
@@ -91,15 +90,11 @@ static PyObject *pygpu_IndexBuf__tp_new(PyTypeObject *UNUSED(type), PyObject *ar
/* Use `INT_MAX` instead of the actual number of vertices. */
GPU_indexbuf_init(&builder, prim_type.value_found, index_len, INT_MAX);
-#if 0
uint *buf = pybuffer.buf;
for (uint i = index_len; i--; buf++) {
GPU_indexbuf_add_generic_vert(&builder, *buf);
}
-#else
- memcpy(builder.data, pybuffer.buf, index_len * sizeof(*builder.data));
- builder.index_len = index_len;
-#endif
+
PyBuffer_Release(&pybuffer);
}
else {