python_shared.cpp 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  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_line_mesh_intersection
  81. embree_reorient_facets_raycast
  82. find_cross_field_singularities
  83. fit_rotations
  84. floor
  85. forward_kinematics
  86. gaussian_curvature
  87. get_seconds
  88. grad
  89. harmonic
  90. hsv_to_rgb
  91. internal_angles
  92. invert_diag
  93. is_irregular_vertex
  94. jet
  95. lbs_matrix
  96. local_basis
  97. lscm
  98. map_vertices_to_circle
  99. massmatrix
  100. min_quad_with_fixed
  101. n_polyvector
  102. normalize_row_lengths
  103. normalize_row_sums
  104. parula
  105. per_corner_normals
  106. per_edge_normals
  107. per_face_normals
  108. per_vertex_normals
  109. planarize_quad_mesh
  110. png_readPNG
  111. png_writePNG
  112. point_mesh_squared_distance
  113. polar_svd
  114. principal_curvature
  115. quad_planarity
  116. randperm
  117. readDMAT
  118. readMESH
  119. readOBJ
  120. readOFF
  121. readTGF
  122. read_triangle_mesh
  123. remove_duplicate_vertices
  124. rotate_vectors
  125. setdiff
  126. signed_distance
  127. slice
  128. slice_into
  129. slice_mask
  130. slice_tets
  131. sortrows
  132. streamlines
  133. triangle_triangle_adjacency
  134. triangle_triangulate
  135. unique
  136. unproject_onto_mesh
  137. upsample
  138. winding_number
  139. writeMESH
  140. writeOBJ
  141. writePLY
  142. )pyigldoc");
  143. python_export_vector(m);
  144. python_export_igl(m);
  145. #ifdef PY_VIEWER
  146. python_export_igl_viewer(m);
  147. #endif
  148. #ifdef PY_COMISO
  149. python_export_igl_comiso(m);
  150. #endif
  151. #ifdef PY_TETGEN
  152. python_export_igl_tetgen(m);
  153. #endif
  154. #ifdef PY_EMBREE
  155. python_export_igl_embree(m);
  156. #endif
  157. #ifdef PY_TRIANGLE
  158. python_export_igl_triangle(m);
  159. #endif
  160. #ifdef PY_CGAL
  161. python_export_igl_cgal(m);
  162. #endif
  163. #ifdef PY_COPYLEFT
  164. python_export_igl_copyleft(m);
  165. #endif
  166. #ifdef PY_PNG
  167. python_export_igl_png(m);
  168. #endif
  169. return m.ptr();
  170. }