diff options
Diffstat (limited to 'source/blender/python/gpu')
-rw-r--r-- | source/blender/python/gpu/gpu_py_api.c | 4 | ||||
-rw-r--r-- | source/blender/python/gpu/gpu_py_api.h | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/python/gpu/gpu_py_api.c b/source/blender/python/gpu/gpu_py_api.c index 1379c0e557a..da7674eb7f9 100644 --- a/source/blender/python/gpu/gpu_py_api.c +++ b/source/blender/python/gpu/gpu_py_api.c @@ -43,9 +43,9 @@ /** \name Utils to invalidate functions * \{ */ -bool bpygpu_is_initialized_or_error(void) +bool bpygpu_is_init_or_error(void) { - if (!GPU_is_initialized()) { + if (!GPU_is_init()) { PyErr_SetString(PyExc_SystemError, "GPU functions for drawing are not available in background mode"); diff --git a/source/blender/python/gpu/gpu_py_api.h b/source/blender/python/gpu/gpu_py_api.h index e278bb63a49..916b1ac6e49 100644 --- a/source/blender/python/gpu/gpu_py_api.h +++ b/source/blender/python/gpu/gpu_py_api.h @@ -25,14 +25,14 @@ int bpygpu_ParsePrimType(PyObject *o, void *p); PyObject *BPyInit_gpu(void); -bool bpygpu_is_initialized_or_error(void); +bool bpygpu_is_init_or_error(void); #define BPYGPU_IS_INIT_OR_ERROR_OBJ \ - if (UNLIKELY(!bpygpu_is_initialized_or_error())) { \ + if (UNLIKELY(!bpygpu_is_init_or_error())) { \ return NULL; \ } \ ((void)0) #define BPYGPU_IS_INIT_OR_ERROR_INT \ - if (UNLIKELY(!bpygpu_is_initialized_or_error())) { \ + if (UNLIKELY(!bpygpu_is_init_or_error())) { \ return -1; \ } \ ((void)0) |