python_shared.cpp 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193
  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. #ifdef PY_TETGEN
  14. extern void python_export_igl_tetgen(py::module &);
  15. #endif
  16. #ifdef PY_EMBREE
  17. extern void python_export_igl_embree(py::module &);
  18. #endif
  19. #ifdef PY_TRIANGLE
  20. extern void python_export_igl_triangle(py::module &);
  21. #endif
  22. #ifdef PY_CGAL
  23. extern void python_export_igl_cgal(py::module &);
  24. #endif
  25. #ifdef PY_COPYLEFT
  26. extern void python_export_igl_copyleft(py::module &);
  27. #endif
  28. #ifdef PY_PNG
  29. extern void python_export_igl_png(py::module &);
  30. #endif
  31. PYBIND11_PLUGIN(pyigl) {
  32. py::module m("pyigl", R"pyigldoc(
  33. Python wrappers for libigl
  34. --------------------------
  35. .. currentmodule:: pyigl
  36. .. autosummary::
  37. :toctree: _generate
  38. AABB
  39. ARAPEnergyType
  40. MeshBooleanType
  41. SolverStatus
  42. active_set
  43. arap
  44. avg_edge_length
  45. barycenter
  46. barycentric_coordinates
  47. barycentric_to_global
  48. bbw
  49. boundary_conditions
  50. boundary_facets
  51. boundary_loop
  52. cat
  53. collapse_edge
  54. colon
  55. column_to_quats
  56. comb_cross_field
  57. comb_frame_field
  58. compute_frame_field_bisectors
  59. copyleft_cgal_RemeshSelfIntersectionsParam
  60. copyleft_cgal_mesh_boolean
  61. copyleft_cgal_remesh_self_intersections
  62. copyleft_comiso_miq
  63. copyleft_comiso_nrosy
  64. copyleft_marching_cubes
  65. copyleft_swept_volume
  66. copyleft_tetgen_tetrahedralize
  67. cotmatrix
  68. covariance_scatter_matrix
  69. cross_field_missmatch
  70. cut_mesh_from_singularities
  71. deform_skeleton
  72. directed_edge_orientations
  73. directed_edge_parents
  74. doublearea
  75. dqs
  76. edge_lengths
  77. edge_topology
  78. eigs
  79. embree_ambient_occlusion
  80. embree_reorient_facets_raycast
  81. find_cross_field_singularities
  82. fit_rotations
  83. floor
  84. forward_kinematics
  85. gaussian_curvature
  86. get_seconds
  87. grad
  88. harmonic
  89. hsv_to_rgb
  90. internal_angles
  91. invert_diag
  92. is_irregular_vertex
  93. jet
  94. lbs_matrix
  95. local_basis
  96. lscm
  97. map_vertices_to_circle
  98. massmatrix
  99. min_quad_with_fixed
  100. n_polyvector
  101. normalize_row_lengths
  102. normalize_row_sums
  103. parula
  104. per_corner_normals
  105. per_edge_normals
  106. per_face_normals
  107. per_vertex_normals
  108. planarize_quad_mesh
  109. png_readPNG
  110. png_writePNG
  111. point_mesh_squared_distance
  112. polar_svd
  113. principal_curvature
  114. quad_planarity
  115. randperm
  116. readDMAT
  117. readMESH
  118. readOBJ
  119. readOFF
  120. readTGF
  121. read_triangle_mesh
  122. remove_duplicate_vertices
  123. rotate_vectors
  124. setdiff
  125. signed_distance
  126. slice
  127. slice_into
  128. slice_mask
  129. slice_tets
  130. sortrows
  131. streamlines
  132. triangle_triangle_adjacency
  133. triangle_triangulate
  134. unique
  135. unproject_onto_mesh
  136. upsample
  137. winding_number
  138. writeMESH
  139. writeOBJ
  140. )pyigldoc");
  141. python_export_vector(m);
  142. python_export_igl(m);
  143. #ifdef PY_VIEWER
  144. python_export_igl_viewer(m);
  145. #endif
  146. #ifdef PY_COMISO
  147. python_export_igl_comiso(m);
  148. #endif
  149. #ifdef PY_TETGEN
  150. python_export_igl_tetgen(m);
  151. #endif
  152. #ifdef PY_EMBREE
  153. python_export_igl_embree(m);
  154. #endif
  155. #ifdef PY_TRIANGLE
  156. python_export_igl_triangle(m);
  157. #endif
  158. #ifdef PY_CGAL
  159. python_export_igl_cgal(m);
  160. #endif
  161. #ifdef PY_COPYLEFT
  162. python_export_igl_copyleft(m);
  163. #endif
  164. #ifdef PY_PNG
  165. python_export_igl_png(m);
  166. #endif
  167. return m.ptr();
  168. }