Download vendor/libigl/include/igl/xml/write_triangle_mesh.cpp from AVSim/simulation-package: direct link, hf CLI and curl.
- Browser
- Download file 1.49 kB
-
https://huggingface.co/datasets/AVSim/simulation-package/resolve/main/vendor/libigl/include/igl/xml/write_triangle_mesh.cpp
- Command line
-
hf download hf://datasets/AVSim/simulation-package/vendor/libigl/include/igl/xml/write_triangle_mesh.cpp
-
curl -L -o write_triangle_mesh.cpp https://huggingface.co/datasets/AVSim/simulation-package/resolve/main/vendor/libigl/include/igl/xml/write_triangle_mesh.cpp
1.49 kB
| // This file is part of libigl, a simple c++ geometry processing library. | |
| // | |
| // Copyright (C) 2016 Alec Jacobson <alecjacobson@gmail.com> | |
| // | |
| // This Source Code Form is subject to the terms of the Mozilla Public License | |
| // v. 2.0. If a copy of the MPL was not distributed with this file, You can | |
| // obtain one at http://mozilla.org/MPL/2.0/. | |
| template <typename DerivedV, typename DerivedF> | |
| IGL_INLINE bool igl::xml::write_triangle_mesh( | |
| const std::string str, | |
| const Eigen::PlainObjectBase<DerivedV>& V, | |
| const Eigen::PlainObjectBase<DerivedF>& F, | |
| const FileEncoding fe) | |
| { | |
| using namespace std; | |
| // dirname, basename, extension and filename | |
| string d,b,e,f; | |
| pathinfo(str,d,b,e,f); | |
| // Convert extension to lower case | |
| std::transform(e.begin(), e.end(), e.begin(), ::tolower); | |
| if(e == "dae") | |
| { | |
| return writeDAE(str,V,F); | |
| }else | |
| { | |
| return igl::write_triangle_mesh(str,V,F,fe); | |
| } | |
| } | |
| // Explicit template instantiation | |
| // generated by autoexplicit.sh | |
| template bool igl::xml::write_triangle_mesh<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1> >(std::basic_string<char, std::char_traits<char>, std::allocator<char> >, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, igl::FileEncoding); | |