python_shared.cpp 650 B

12345678910111213141516171819202122232425262728293031323334
  1. #include "python_shared.h"
  2. #include <sstream>
  3. #include <string>
  4. #include <fstream>
  5. extern void python_export_vector(py::module &);
  6. extern void python_export_igl(py::module &);
  7. #ifdef PY_VIEWER
  8. extern void python_export_igl_viewer(py::module &);
  9. #endif
  10. #ifdef PY_COMISO
  11. extern void python_export_igl_comiso(py::module &);
  12. #endif
  13. PYTHON_PLUGIN(pyigl) {
  14. py::init_threading();
  15. py::module m("pyigl", "Python wrappers for libigl");
  16. python_export_vector(m);
  17. python_export_igl(m);
  18. #ifdef PY_VIEWER
  19. python_export_igl_viewer(m);
  20. #endif
  21. #ifdef PY_COMISO
  22. python_export_igl_comiso(m);
  23. #endif
  24. return m.ptr();
  25. }