diff options
author | Howard Trickey <howard.trickey@gmail.com> | 2020-08-28 18:43:56 +0300 |
---|---|---|
committer | Howard Trickey <howard.trickey@gmail.com> | 2020-08-28 18:43:56 +0300 |
commit | 4749bd227723459097c246aa8a77c74545bc36ef (patch) | |
tree | b3de9aea76341dd5edeb8603ff0446603f4a5523 | |
parent | 9e09b5c418c0a436e3c84ccf38c065527988b0a0 (diff) |
Fix to previous commit to allow building without WITH_GMP.
-rw-r--r-- | source/blender/blenlib/intern/math_vec.cc | 2 | ||||
-rw-r--r-- | source/blender/blenlib/tests/BLI_mesh_boolean_test.cc | 2 | ||||
-rw-r--r-- | source/blender/blenlib/tests/BLI_mesh_intersect_test.cc | 2 |
3 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/math_vec.cc b/source/blender/blenlib/intern/math_vec.cc index 865a1986214..54926f84eb9 100644 --- a/source/blender/blenlib/intern/math_vec.cc +++ b/source/blender/blenlib/intern/math_vec.cc @@ -146,6 +146,7 @@ double3 double3::cross_poly(Span<double3> poly) return n; } +#ifdef WITH_GMP mpq3 mpq3::cross_poly(Span<mpq3> poly) { /* Newell's Method. */ @@ -189,5 +190,6 @@ uint64_t mpq3::hash() const uint64_t hashz = hash_mpq_class(this->z); return hashx ^ (hashy * 33) ^ (hashz * 33 * 37); } +#endif } // namespace blender diff --git a/source/blender/blenlib/tests/BLI_mesh_boolean_test.cc b/source/blender/blenlib/tests/BLI_mesh_boolean_test.cc index af8856a2e15..b212ddb8e63 100644 --- a/source/blender/blenlib/tests/BLI_mesh_boolean_test.cc +++ b/source/blender/blenlib/tests/BLI_mesh_boolean_test.cc @@ -15,6 +15,7 @@ #include "BLI_mpq3.hh" #include "BLI_vector.hh" +#ifdef WITH_GMP namespace blender::meshintersect::tests { constexpr bool DO_OBJ = false; @@ -906,3 +907,4 @@ TEST(boolean_polymesh, CubePlane) } } // namespace blender::meshintersect::tests +#endif diff --git a/source/blender/blenlib/tests/BLI_mesh_intersect_test.cc b/source/blender/blenlib/tests/BLI_mesh_intersect_test.cc index 6d24c4e6c03..f3890bcebb2 100644 --- a/source/blender/blenlib/tests/BLI_mesh_intersect_test.cc +++ b/source/blender/blenlib/tests/BLI_mesh_intersect_test.cc @@ -18,6 +18,7 @@ #define DO_REGULAR_TESTS 1 #define DO_PERF_TESTS 0 +#ifdef WITH_GMP namespace blender::meshintersect::tests { constexpr bool DO_OBJ = false; @@ -1070,3 +1071,4 @@ TEST(mesh_intersect_perf, SphereGrid) #endif } // namespace blender::meshintersect::tests +#endif |