assign_scalar.h 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. // This file is part of libigl, a simple c++ geometry processing library.
  2. //
  3. // Copyright (C) 2015 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. #ifndef IGL_COPYLEFT_CGAL_ASSIGN_SCALAR_H
  9. #define IGL_COPYLEFT_CGAL_ASSIGN_SCALAR_H
  10. #include "../../igl_inline.h"
  11. #include <CGAL/Exact_predicates_exact_constructions_kernel.h>
  12. #include <CGAL/Exact_predicates_exact_constructions_kernel_with_sqrt.h>
  13. #ifndef WIN32
  14. #include <CGAL/gmpxx.h>
  15. #endif
  16. namespace igl
  17. {
  18. namespace copyleft
  19. {
  20. namespace cgal
  21. {
  22. // Inputs:
  23. // cgal cgal scalar
  24. // Outputs:
  25. // d output scalar
  26. IGL_INLINE void assign_scalar(
  27. const CGAL::Epeck::FT & cgal,
  28. CGAL::Epeck::FT & d);
  29. IGL_INLINE void assign_scalar(
  30. const CGAL::Epeck::FT & cgal,
  31. double & d);
  32. IGL_INLINE void assign_scalar(
  33. const CGAL::Epeck::FT & cgal,
  34. float& d);
  35. IGL_INLINE void assign_scalar(
  36. const double & c,
  37. double & d);
  38. IGL_INLINE void assign_scalar(
  39. const float& c,
  40. float & d);
  41. IGL_INLINE void assign_scalar(
  42. const float& c,
  43. double& d);
  44. IGL_INLINE void assign_scalar(
  45. const CGAL::Exact_predicates_exact_constructions_kernel_with_sqrt::FT & cgal,
  46. CGAL::Exact_predicates_exact_constructions_kernel_with_sqrt::FT & d);
  47. IGL_INLINE void assign_scalar(
  48. const CGAL::Exact_predicates_exact_constructions_kernel_with_sqrt::FT & cgal,
  49. double & d);
  50. IGL_INLINE void assign_scalar(
  51. const CGAL::Exact_predicates_exact_constructions_kernel_with_sqrt::FT & cgal,
  52. float& d);
  53. #ifndef WIN32
  54. IGL_INLINE void assign_scalar(
  55. const CGAL::Simple_cartesian<mpq_class>::FT & cgal,
  56. CGAL::Simple_cartesian<mpq_class>::FT & d);
  57. IGL_INLINE void assign_scalar(
  58. const CGAL::Simple_cartesian<mpq_class>::FT & cgal,
  59. double & d);
  60. IGL_INLINE void assign_scalar(
  61. const CGAL::Simple_cartesian<mpq_class>::FT & cgal,
  62. float& d);
  63. #endif // WIN32
  64. }
  65. }
  66. }
  67. #ifndef IGL_STATIC_LIBRARY
  68. # include "assign_scalar.cpp"
  69. #endif
  70. #endif