mirror of https://github.com/CGAL/cgal
Concept fixes
This commit is contained in:
parent
085ac024ac
commit
1ee5b90f1b
|
|
@ -43,8 +43,6 @@ public:
|
|||
using Point_3 = typename Geom_traits::Point_3;
|
||||
using Vector_3 = typename Geom_traits::Vector_3;
|
||||
|
||||
using Vertex_descriptor = Isosurfacing::internal::Grid_topology_3::Vertex_descriptor;
|
||||
|
||||
private:
|
||||
Bbox_3 m_bbox;
|
||||
Vector_3 m_spacing;
|
||||
|
|
@ -187,11 +185,6 @@ public:
|
|||
m_bbox.zmin() + z * x_coord(m_spacing));
|
||||
}
|
||||
|
||||
const Point_3& point(const Vertex_descriptor& v) const
|
||||
{
|
||||
return point(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
/**
|
||||
* \brief gets the scalar value stored at the grid vertex described by a set of indices.
|
||||
*
|
||||
|
|
@ -208,11 +201,6 @@ public:
|
|||
return m_values[linear_index(x, y, z)];
|
||||
}
|
||||
|
||||
FT value(const Vertex_descriptor& v) const
|
||||
{
|
||||
return value(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
/**
|
||||
* \brief gets the scalar value stored at the grid vertex described by a set of indices.
|
||||
*
|
||||
|
|
@ -231,11 +219,6 @@ public:
|
|||
return m_values[linear_index(x, y, z)];
|
||||
}
|
||||
|
||||
FT& value(const Vertex_descriptor& v)
|
||||
{
|
||||
return value(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
/**
|
||||
* \brief gets the gradient stored at the grid vertex described by a set of indices.
|
||||
*
|
||||
|
|
@ -250,11 +233,6 @@ public:
|
|||
return m_gradients[linear_index(x, y, z)];
|
||||
}
|
||||
|
||||
const Vector_3& gradient(const Vertex_descriptor& v) const
|
||||
{
|
||||
return gradient(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
/**
|
||||
* \brief gets the gradient stored at the grid vertex described by a set of indices.
|
||||
*
|
||||
|
|
@ -273,11 +251,6 @@ public:
|
|||
return m_gradients[linear_index(x, y, z)];
|
||||
}
|
||||
|
||||
Vector_3& gradient(const Vertex_descriptor& v)
|
||||
{
|
||||
return gradient(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
private:
|
||||
std::size_t linear_index(const std::size_t x,
|
||||
const std::size_t y,
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ namespace Isosurfacing {
|
|||
* \tparam Gradient the type of the gradient functor. It must be a model of `CopyConstructible` and implement
|
||||
* `GeomTraits::Vector_3 operator()(const GeomTraits::Point_3& point) const`.
|
||||
*/
|
||||
#ifdef DOXYGEN_RUNNING // Allow more than a CGAL::Cartesian_grid_3
|
||||
#ifdef DOXYGEN_RUNNING // Allow more than a Cartesian_grid_3
|
||||
template <template <typename GeomTraits> class Cartesian_grid_3,
|
||||
typename Gradient = Zero_gradient>
|
||||
class Explicit_Cartesian_grid_domain_3;
|
||||
|
|
@ -69,7 +69,7 @@ using Explicit_Cartesian_grid_domain_3 =
|
|||
*
|
||||
* \return a new `Explicit_Cartesian_grid_domain_3`
|
||||
*/
|
||||
#ifdef DOXYGEN_RUNNING // Allow more than CGAL::Cartesian_grid_3
|
||||
#ifdef DOXYGEN_RUNNING // Allow more than Cartesian_grid_3
|
||||
template <typename GeomTraits,
|
||||
typename Gradient = Zero_gradient>
|
||||
Explicit_Cartesian_grid_domain_3<Grid, Gradient>
|
||||
|
|
|
|||
|
|
@ -26,10 +26,15 @@ namespace Isosurfacing {
|
|||
*
|
||||
* \details The gradient at any point is calculated using trilinear interpolation.
|
||||
*
|
||||
* \tparam Grid must be a model of `CartesianGrid_3`.
|
||||
* \tparam GeomTraits must be a model of `IsosurfacingTraits_3`.
|
||||
*/
|
||||
#ifdef DOXYGEN_RUNNING // Allow more than just Cartesian_grid_3
|
||||
template <template <typename GeomTraits> class Cartesian_grid_3>
|
||||
class Explicit_Cartesian_grid_gradient_3
|
||||
#else
|
||||
template <typename Grid>
|
||||
class Explicit_Cartesian_grid_gradient_3
|
||||
#endif
|
||||
{
|
||||
public:
|
||||
using Geom_traits = typename Grid::Geom_traits;
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ public:
|
|||
// gets the value at vertex `v`
|
||||
FT operator()(const Vertex_descriptor& v) const
|
||||
{
|
||||
return grid.value(v);
|
||||
return grid.value(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
private:
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ public:
|
|||
// gets the position of vertex `v`
|
||||
decltype(auto) /*Point_3*/ operator()(const Vertex_descriptor& v) const
|
||||
{
|
||||
return m_grid.point(v);
|
||||
return m_grid.point(v[0], v[1], v[2]);
|
||||
}
|
||||
|
||||
private:
|
||||
|
|
|
|||
Loading…
Reference in New Issue