python_shared.cpp 4.4 KB

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