mapping_energy_with_jacobians.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. // This file is part of libigl, a simple c++ geometry processing library.
  2. //
  3. // Copyright (C) 2018 Zhongshi Jiang <[email protected]>
  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. #ifndef IGL_MAPPING_ENERGY_WITH_JACOBIANS_H
  9. #define IGL_MAPPING_ENERGY_WITH_JACOBIANS_H
  10. #include "igl_inline.h"
  11. #include "MappingEnergyType.h"
  12. #include <Eigen/Dense>
  13. namespace igl
  14. {
  15. /// Compute the rotation-invariant energy of a mapping (represented in Jacobians and areas)
  16. ///
  17. /// @param[in] Ji #F by 4 (9 if 3D) entries of jacobians
  18. /// @param[in] areas: #F by 1 face areas
  19. /// @param[in] slim_energy energy type as in igl::MappingEnergyType
  20. /// @param[in] exp_factor see igl::MappingEnergyType
  21. /// @return energy value
  22. ///
  23. ///
  24. /// \see MappingEnergyType
  25. IGL_INLINE double mapping_energy_with_jacobians(
  26. const Eigen::MatrixXd &Ji,
  27. const Eigen::VectorXd &areas,
  28. igl::MappingEnergyType slim_energy,
  29. double exp_factor);
  30. }
  31. #ifndef IGL_STATIC_LIBRARY
  32. # include "mapping_energy_with_jacobians.cpp"
  33. #endif
  34. #endif