Commit 04c40b6c authored by Sylvain Thery's avatar Sylvain Thery

mac compilation pass on test

parent e9606c65
......@@ -76,11 +76,11 @@ template void Algo::Surface::Geometry::computeRidgeLines<PFP1>(
const VertexAttribute<PFP1::REAL, PFP1::MAP>& k2,
FaceAttribute<ridgeSegment, PFP1::MAP>& ridge_segments) ;
template void Algo::Surface::Geometry::ridgeLines<PFP1>(
PFP1::MAP& map,
Dart d,
const VertexAttribute<PFP1::VEC3, PFP1::MAP>& position,
const FaceAttribute<PFP1::VEC3, PFP1::MAP>& face_area,
const VertexAttribute<PFP1::VEC3, PFP1::MAP>& K,
const VertexAttribute<PFP1::VEC3, PFP1::MAP>& vertex_gradient,
const VertexAttribute<PFP1::REAL, PFP1::MAP>& k,
......@@ -174,7 +174,6 @@ template void Algo::Surface::Geometry::ridgeLines<PFP2>(
PFP2::MAP& map,
Dart d,
const VertexAttribute<PFP2::VEC3, PFP2::MAP>& position,
const FaceAttribute<PFP2::VEC3, PFP2::MAP>& face_area,
const VertexAttribute<PFP2::VEC3, PFP2::MAP>& K,
const VertexAttribute<PFP2::VEC3, PFP2::MAP>& vertex_gradient,
const VertexAttribute<PFP2::REAL, PFP2::MAP>& k,
......@@ -207,4 +206,4 @@ template std::vector<PFP2::VEC3> Algo::Surface::Geometry::occludingContoursDetec
int test_feature()
{
return 0;
}
\ No newline at end of file
}
......@@ -9,14 +9,14 @@ using namespace CGoGN;
template Geom::Inclusion Geom::isPointInTriangle(const Geom::Vec3f& point, const Geom::Vec3f& Ta, const Geom::Vec3f& Tb, const Geom::Vec3f& Tc);
template bool Geom::isPointInSphere(const Geom::Vec3f& point, const Geom::Vec3f& center, const float& radius);
template Geom::Inclusion Geom::isSegmentInTriangle(const Geom::Vec3f& P1, const Geom::Vec3f& P2, const Geom::Vec3f& Ta, const Geom::Vec3f& Tb, const Geom::Vec3f& Tc, const Geom::Vec3f& N);
template Geom::Inclusion Geom::isSegmentInTriangle2D(const Geom::Vec3f& P1, const Geom::Vec3f& P2, const Geom::Vec3f& Ta, const Geom::Vec3f& Tb, const Geom::Vec3f& Tc, const Geom::Vec3f& N);
template bool Geom::isPointInTetrahedron(Geom::Vec3f points[4], Geom::Vec3f& point, bool);
template bool Geom::isEdgeInOrIntersectingTetrahedron(Geom::Vec3f points[4], Geom::Vec3f& point1, Geom::Vec3f& point2, bool CCW);
template bool Geom::arePointsEquals(const Geom::Vec3f& point1, const Geom::Vec3f& point2);
template Geom::Inclusion Geom::isPointInTriangle(const Geom::Vec3d& point, const Geom::Vec3d& Ta, const Geom::Vec3d& Tb, const Geom::Vec3d& Tc);
template bool Geom::isPointInSphere(const Geom::Vec3d& point, const Geom::Vec3d& center, const double& radius);
template Geom::Inclusion Geom::isSegmentInTriangle(const Geom::Vec3d& P1, const Geom::Vec3d& P2, const Geom::Vec3d& Ta, const Geom::Vec3d& Tb, const Geom::Vec3d& Tc, const Geom::Vec3d& N);
template Geom::Inclusion Geom::isSegmentInTriangle2D(const Geom::Vec3d& P1, const Geom::Vec3d& P2, const Geom::Vec3d& Ta, const Geom::Vec3d& Tb, const Geom::Vec3d& Tc, const Geom::Vec3d& N);
template bool Geom::isPointInTetrahedron(Geom::Vec3d points[4], Geom::Vec3d& point, bool);
template bool Geom::isEdgeInOrIntersectingTetrahedron(Geom::Vec3d points[4], Geom::Vec3d& point1, Geom::Vec3d& point2, bool CCW);
template bool Geom::arePointsEquals(const Geom::Vec3d& point1, const Geom::Vec3d& point2);
......
......@@ -128,7 +128,7 @@ void ridgeLines(
typename PFP::MAP& map,
Dart d,
const VertexAttribute<typename PFP::VEC3, typename PFP::MAP>& position,
const FaceAttribute<typename PFP::VEC3, typename PFP::MAP>& face_area,
// const FaceAttribute<typename PFP::VEC3, typename PFP::MAP>& face_area,
const VertexAttribute<typename PFP::VEC3, typename PFP::MAP>& K,
const VertexAttribute<typename PFP::VEC3, typename PFP::MAP>& vertex_gradient,
const VertexAttribute<typename PFP::REAL, typename PFP::MAP>& k,
......
......@@ -41,7 +41,7 @@ namespace Geometry
template <typename PFP>
void featureEdgeDetection(
typename PFP::MAP& map,
VertexAttribute<typename PFP::VEC3, typename PFP::MAP>& position,
const VertexAttribute<typename PFP::VEC3, typename PFP::MAP>& position,
CellMarker<typename PFP::MAP, EDGE>& featureEdge)
{
typedef typename PFP::MAP MAP ;
......@@ -50,9 +50,9 @@ void featureEdgeDetection(
featureEdge.unmarkAll() ;
FaceAttribute<VEC3, MAP> fNormal = map.template getAttribute<VEC3, FACE>("normal") ;
FaceAttribute<VEC3, MAP> fNormal = map.template getAttribute<VEC3, FACE, typename PFP::MAP>("normal") ;
if(!fNormal.isValid())
fNormal = map.template addAttribute<VEC3, FACE>("normal") ;
fNormal = map.template addAttribute<VEC3, FACE, typename PFP::MAP>("normal") ;
Algo::Surface::Geometry::computeNormalFaces<PFP>(map, position, fNormal) ;
TraversorE<MAP> t(map) ;
......
......@@ -56,7 +56,7 @@ bool isConvex(typename PFP::MAP& map, Vol v, const VertexAttribute<typename PFP:
Dart e = *it;
if (!m.isMarked(e))
{
m.markOrbit<EDGE>(e) ;
m.template markOrbit<EDGE>(e) ;
convex = isTetrahedronWellOriented<PFP>(map, e, position, CCW) ;
}
}
......
......@@ -136,7 +136,7 @@ typename V_ATT::DATA_TYPE vertexBorderNormal(typename PFP::MAP& map, Vertex v, c
for(std::vector<Dart>::iterator it = faces.begin() ; it != faces.end() ; ++it)
{
// if(!f.isMarked(*it) && map.isBoundaryIncidentFace(*it))
if (!f.isMarked(*it) && (map.isBoundaryMarked<3>(map.phi3(*it))))
if (!f.isMarked(*it) && (map.template isBoundaryMarked<3>(map.phi3(*it))))
{
f.mark(*it);
VEC3 n = faceNormal<PFP>(map, *it, position);
......
......@@ -801,8 +801,8 @@ void TwoNPlusOneSubdivision(typename PFP::MAP& map, EMBV& attributs, float size)
map.cutEdge(map.phi1(dd));
mCorner.mark(map.phi2(map.phi1(dd)));
// attributs[map.template phi<11>(dd)] = c*(1.0-size)+ attributs[dd]*size;
attributs[map.template phi<11>(dd)] = attributs[dd] + Geometry::vectorOutOfDart<PFP>(map,dd,attributs)
- Geometry::vectorOutOfDart<PFP>(map,map.phi_1(dd),attributs);
attributs[map.template phi<11>(dd)] = attributs[dd] + Algo::Geometry::vectorOutOfDart<PFP>(map,dd,attributs)
- Algo::Geometry::vectorOutOfDart<PFP>(map,map.phi_1(dd),attributs);
dd = map.phi1(map.phi1(map.phi1(map.phi2(map.phi1(dd)))));
} while(!mCorner.isMarked(dd));
}
......
......@@ -142,7 +142,7 @@ Dart sliceConvexVolume(typename PFP::MAP& map, VertexAttribute<typename PFP::VEC
else
{
VEC3 interP;
VEC3 vec(Surface::Geometry::vectorOutOfDart<PFP>(map,dd,position));
VEC3 vec(Algo::Geometry::vectorOutOfDart<PFP>(map,dd,position));
Geom::Intersection inter = Geom::intersectionLinePlane<VEC3, typename Geom::Plane3D<REAL> >(position[dd],vec,pl,interP);
if(inter==Geom::FACE_INTERSECTION)
......
......@@ -1257,7 +1257,7 @@ void Collector_Dijkstra<PFP>::collectBorder(Dart dinit)
template <typename PFP>
inline float Collector_Dijkstra<PFP>::edgeLength (Dart d)
{
typename PFP::VEC3 v = Geometry::vectorOutOfDart<PFP>(this->map, d, this->position);
typename PFP::VEC3 v = Algo::Geometry::vectorOutOfDart<PFP>(this->map, d, this->position);
return v.norm();
}
......
......@@ -118,7 +118,7 @@ template <typename VEC>
typename VEC::DATA_TYPE BoundingBox<VEC>::diagSize() const
{
assert(m_initialized || !"Bounding box not initialized");
return VEC::DATA_TYPE((m_pMax - m_pMin).norm());
return typename VEC::DATA_TYPE((m_pMax - m_pMin).norm());
}
template <typename VEC>
......
......@@ -269,7 +269,7 @@ template <typename VEC3>
bool lineLineClosestPoints(const VEC3& P1, const VEC3& V1, const VEC3& P2, const VEC3& V2, VEC3& Q1, VEC3& Q2)
{
typedef typename VEC3::DATA_TYPE SCAL;
typename VEC3 P12 = P1 - P2;
VEC3 P12 = P1 - P2;
SCAL d1343 = P12 * V2;
SCAL d4321 = V2*V1;
......
......@@ -67,7 +67,7 @@ bool isPointInSphere(const VEC3& point, const VEC3& center, const typename VEC3:
* @param N the normal of the triangle
*/
template <typename VEC3>
Inclusion isSegmentInTriangle(const VEC3& P1, const VEC3& P2, const VEC3& Ta, const VEC3& Tb, const VEC3& Tc, const VEC3& N) ;
Inclusion isSegmentInTriangle2D(const VEC3& P1, const VEC3& P2, const VEC3& Ta, const VEC3& Tb, const VEC3& Tc, const VEC3& N) ;
/**
* test if a point is inside a tetrahedron
......
......@@ -522,19 +522,19 @@ Intersection intersectionSegmentPlan(const VEC3& PA, const VEC3& PB, const VEC3&
typename VEC3::DATA_TYPE panp = NormP * (PA-PlaneP);
typename VEC3::DATA_TYPE pbnp = NormP * (PB-PlaneP);
if(abs(panp) < EPSILON)
if(fabs(panp) < EPSILON)
{
Inter = PA;
return VERTEX_INTERSECTION;
}
else if(abs(pbnp) < EPSILON)
else if(fabs(pbnp) < EPSILON)
{
Inter = PB;
return VERTEX_INTERSECTION;
}
else if (panp*pbnp < 0)
{
Inter = (abs(panp)*PB + abs(pbnp)*PA)/(abs(panp)+abs(pbnp)) ;
Inter = (fabs(panp)*PB + fabs(pbnp)*PA)/(fabs(panp)+fabs(pbnp)) ;
return EDGE_INTERSECTION;
}
else
......
......@@ -23,6 +23,7 @@
*******************************************************************************/
#include <algorithm>
#include <cmath>
#include <cassert>
namespace CGoGN {
......
......@@ -532,7 +532,7 @@ public:
*
* \return the stream reference
*/
friend std::istream& operator>>(std::istream& in, QuadricHF<REAL>& q)
friend std::istream& operator>>(std::istream& in, QuadricHF<REAL>& /*q*/)
{
// TODO
// in >> q.A ;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment