Now Mpzf is used for up to Delaunay_d<6>
This commit is contained in:
@@ -49,7 +49,7 @@ struct Epick_d_help1
|
||||
};
|
||||
#undef CGAL_BASE
|
||||
// determinant is only safe for use with integers with this condition, see LA_eigen/LA.h
|
||||
#if _MSC_VER >= 1911 || __cpp_if_constexpr >= 201606L
|
||||
|
||||
#define CGAL_BASE \
|
||||
Cartesian_filter_K< \
|
||||
Epick_d_help1<Dim>, \
|
||||
@@ -67,10 +67,7 @@ struct Epick_d_help2
|
||||
#undef CGAL_BASE
|
||||
#define CGAL_BASE \
|
||||
Cartesian_static_filters<Dim,Epick_d_help2<Dim>,Epick_d_help3<Dim> >
|
||||
#else
|
||||
#define CGAL_BASE \
|
||||
Cartesian_static_filters<Dim,Epick_d_help1<Dim>,Epick_d_help3<Dim> >
|
||||
#endif
|
||||
|
||||
template<class Dim>
|
||||
struct Epick_d_help3
|
||||
: CGAL_BASE
|
||||
|
||||
@@ -47,7 +47,7 @@ template<> struct Functors_without_division<Dimension_tag<5> > {
|
||||
typedef typeset<Orientation_of_points_tag, Side_of_oriented_sphere_tag> type;
|
||||
};
|
||||
template<> struct Functors_without_division<Dimension_tag<6> > {
|
||||
typedef typeset<Orientation_of_points_tag> type;
|
||||
typedef typeset<Orientation_of_points_tag, Side_of_oriented_sphere_tag> type;
|
||||
};
|
||||
|
||||
template < typename Base_, typename AK_, typename EK_, typename Pred_list = typeset_all >
|
||||
|
||||
@@ -115,6 +115,13 @@ template<class NT_,class Dim_,class Max_dim_=Dim_> struct LA_eigen {
|
||||
return (int)v.cols();
|
||||
}
|
||||
|
||||
template<class Mat_> static NT determinant_aux(Mat_ const& m, Tag_true) {
|
||||
CGAL_assume(false);
|
||||
}
|
||||
template<class Mat_> static NT determinant_aux(Mat_ const& m, Tag_false) {
|
||||
return m.determinant();
|
||||
}
|
||||
|
||||
template<class Mat_> static NT determinant(Mat_ const&m,bool=false){
|
||||
switch(m.rows()){
|
||||
//case 0:
|
||||
@@ -161,14 +168,8 @@ template<class NT_,class Dim_,class Max_dim_=Dim_> struct LA_eigen {
|
||||
m(5,0),m(5,1),m(5,2),m(5,3),m(5,4),m(5,5),m(5,6),
|
||||
m(6,0),m(6,1),m(6,2),m(6,3),m(6,4),m(6,5),m(6,6));
|
||||
default:
|
||||
#if _MSC_VER >= 1911 || __cpp_if_constexpr >= 201606L
|
||||
// Avoid compiling the LU decomposition for nothing
|
||||
if constexpr (Mat_::MaxRowsAtCompileTime >= 1 && Mat_::MaxRowsAtCompileTime <= 6) {
|
||||
CGAL_assume(false);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
return m.determinant();
|
||||
return determinant_aux(m, Boolean_tag<(Mat_::MaxRowsAtCompileTime >= 1 && Mat_::MaxRowsAtCompileTime <= 7)>());
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user