12 #include "../generic/py_capi_utils.h"
14 #ifdef WITH_OPENSUBDIV
21 {
"supported",
"Boolean, True when Blender is built with OpenSubdiv support"},
22 {
"version",
"The OpenSubdiv version as a tuple of 3 numbers"},
23 {
"version_string",
"The OpenSubdiv version formatted as a string"},
29 "This module contains information about OpenSubdiv blender is linked against",
36 PyObject *opensubdiv_info;
40 if (opensubdiv_info ==
NULL) {
44 #ifndef WITH_OPENSUBDIV
45 # define SetStrItem(str) \
46 PyStructSequence_SET_ITEM(opensubdiv_info, pos++, PyUnicode_FromString(str))
49 #define SetObjItem(obj) PyStructSequence_SET_ITEM(opensubdiv_info, pos++, obj)
51 #ifdef WITH_OPENSUBDIV
56 "%2d, %2d, %2d", curversion / 10000, (curversion / 100) % 100, curversion % 100));
64 Py_DECREF(opensubdiv_info);
71 return opensubdiv_info;
PyObject * BPY_app_opensubdiv_struct(void)
static PyStructSequence_Field app_opensubdiv_info_fields[]
static PyStructSequence_Desc app_opensubdiv_info_desc
static PyTypeObject BlenderAppOpenSubdivType
static PyObject * make_opensubdiv_info(void)
int openSubdiv_getVersionHex()
#define PyC_Tuple_Pack_I32(...)