read_triangle_mesh.cpp 766 B

1234567891011121314151617181920212223242526
  1. // This file is part of libigl, a simple c++ geometry processing library.
  2. //
  3. // Copyright (C) 2016 Alec Jacobson <alecjacobson@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. #include "read_triangle_mesh.h"
  9. #include "assign.h"
  10. #include "../../read_triangle_mesh.h"
  11. template <typename DerivedV, typename DerivedF>
  12. IGL_INLINE bool igl::copyleft::cgal::read_triangle_mesh(
  13. const std::string str,
  14. Eigen::PlainObjectBase<DerivedV>& V,
  15. Eigen::PlainObjectBase<DerivedF>& F)
  16. {
  17. Eigen::MatrixXd Vd;
  18. bool ret = igl::read_triangle_mesh(str,Vd,F);
  19. if(ret)
  20. {
  21. assign(Vd,V);
  22. }
  23. return ret;
  24. }