pvpythonmodules.h
Go to the documentation of this file.
1 #ifndef pvpythonmodules_h
2 #define pvpythonmodules_h
3 #include "vtkpythonmodules.h"
4 #define PY_APPEND_INIT(module) PyImport_AppendInittab("." #module, PyInit_ ## module)
5 #define PY_IMPORT(module) { \
6  PyObject* var_ ## module = PyInit_ ## module(); \
7  PyDict_SetItemString(PyImport_GetModuleDict(), "." #module,var_ ## module); \
8  Py_DECREF(var_ ## module); }
9 
10 #define PY_APPEND_INIT_OR_IMPORT(module, do_import) \
11  if (do_import) { PY_IMPORT(module); } else { PY_APPEND_INIT(module); }
12 
13 static void pvpythonmodules_load() {
15 }
16 #undef PY_APPEND_INIT
17 #undef PY_IMPORT
18 #undef PY_APPEND_INIT_OR_IMPORT
19 #endif
static void pvpythonmodules_load()
static void vtkpythonmodules_load()