py_boundary_conditions.cpp 972 B

12345678910111213141516171819202122232425262728293031
  1. // This file is part of libigl, a simple c++ geometry processing library.
  2. //
  3. // Copyright (C) 2017 Sebastian Koch <s.koch@tu-berlin.de> and Daniele Panozzo <daniele.panozzo@gmail.com>
  4. //
  5. // This Source Code Form is subject to the terms of the Mozilla Public License
  6. // v. 2.0. If a copy of the MPL was not distributed with this file, You can
  7. // obtain one at http://mozilla.org/MPL/2.0/.
  8. m.def("boundary_conditions", []
  9. (
  10. const Eigen::MatrixXd& V,
  11. const Eigen::MatrixXi& Ele,
  12. const Eigen::MatrixXd& C,
  13. const Eigen::MatrixXi& P,
  14. const Eigen::MatrixXi& BE,
  15. const Eigen::MatrixXi& CE,
  16. Eigen::MatrixXi& b,
  17. Eigen::MatrixXd& bc
  18. )
  19. {
  20. assert_is_VectorX("P", P);
  21. Eigen::VectorXi Pv;
  22. if (P.size() != 0)
  23. Pv = P;
  24. Eigen::VectorXi bv;
  25. igl::boundary_conditions(V, Ele, C, Pv, BE, CE, bv, bc);
  26. b = bv;
  27. }, __doc_igl_boundary_conditions,
  28. py::arg("V"), py::arg("Ele"), py::arg("C"), py::arg("P"), py::arg("BE"), py::arg("CE"), py::arg("b"), py::arg("bc"));