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:
authorCampbell Barton <ideasman42@gmail.com>2017-10-06 13:25:33 +0300
committerCampbell Barton <ideasman42@gmail.com>2017-10-06 13:25:33 +0300
commitea606a7847a316a82b365155f666b33e81ff4c2e (patch)
treed58158c83fd66000fbe9db0c45fa39b6fc02076e /source/blender/python/intern/gpu.c
parentd7d32ad45217736c677edd22906d980d03aeb175 (diff)
parent3df139c53062a141403ea9d359715ca3635c243c (diff)
Merge branch 'master' into blender28
Diffstat (limited to 'source/blender/python/intern/gpu.c')
-rw-r--r--source/blender/python/intern/gpu.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/source/blender/python/intern/gpu.c b/source/blender/python/intern/gpu.c
index d3453c94450..a7a0ae78f26 100644
--- a/source/blender/python/intern/gpu.c
+++ b/source/blender/python/intern/gpu.c
@@ -207,7 +207,7 @@ PyDoc_STRVAR(GPU_export_shader_doc,
" :return: Dictionary defining the shader, uniforms and attributes.\n"
" :rtype: Dict"
);
-static PyObject *GPU_export_shader(PyObject *UNUSED(self), PyObject *args, PyObject *kwds)
+static PyObject *GPU_export_shader(PyObject *UNUSED(self), PyObject *args, PyObject *kw)
{
PyObject *pyscene;
PyObject *pymat;
@@ -224,11 +224,14 @@ static PyObject *GPU_export_shader(PyObject *UNUSED(self), PyObject *args, PyObj
GPUInputUniform *uniform;
GPUInputAttribute *attribute;
- static const char *kwlist[] = {"scene", "material", NULL};
-
- if (!PyArg_ParseTupleAndKeywords(args, kwds, "OO:export_shader", (char **)(kwlist), &pyscene, &pymat))
+ static const char *_keywords[] = {"scene", "material", NULL};
+ static _PyArg_Parser _parser = {"OO:export_shader", _keywords, 0};
+ if (!_PyArg_ParseTupleAndKeywordsFast(
+ args, kw, &_parser,
+ &pyscene, &pymat))
+ {
return NULL;
-
+ }
scene = (Scene *)PyC_RNA_AsPointer(pyscene, "Scene");
if (scene == NULL) {
return NULL;