Skip to content
Snippets Groups Projects
Commit 58ee19fd authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

fix pb with max template

parent 53b67882
Branches
Tags
No related merge requests found
...@@ -56,12 +56,6 @@ ...@@ -56,12 +56,6 @@
#include <BRepBuilderAPI_Transform.hxx> #include <BRepBuilderAPI_Transform.hxx>
template <typename T>
T max(T const &a, T const &b)
{
return a<b? b:a;
}
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
// Printing routines // Printing routines
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
...@@ -150,7 +144,7 @@ int OCC_Connect::SaveBRep(char const *name) ...@@ -150,7 +144,7 @@ int OCC_Connect::SaveBRep(char const *name)
p.RemoveFirst() p.RemoveFirst()
) )
BB.Add(compound,p.First()); BB.Add(compound,p.First());
BRepTools::Write(compound,name); BRepTools::Write(compound, (char*)name);
} }
void OCC_Connect::Dump(ostream &out) const void OCC_Connect::Dump(ostream &out) const
...@@ -600,7 +594,7 @@ void OCC_Connect::Intersect(BRep_Builder &BB, TopoDS_Shape &target, ...@@ -600,7 +594,7 @@ void OCC_Connect::Intersect(BRep_Builder &BB, TopoDS_Shape &target,
BRepExtrema_ExtPC distance(vertex,edge); BRepExtrema_ExtPC distance(vertex,edge);
if(!distance.IsDone()) if(!distance.IsDone())
continue; continue;
double tolerance=max(BRep_Tool::Tolerance(edge), double tolerance=std::max(BRep_Tool::Tolerance(edge),
BRep_Tool::Tolerance(vertex)); BRep_Tool::Tolerance(vertex));
for(int i=1;i<=distance.NbExt();i++) { for(int i=1;i<=distance.NbExt();i++) {
if(distance.Value(i)<tolerance) { if(distance.Value(i)<tolerance) {
...@@ -652,7 +646,7 @@ void OCC_Connect::Intersect(BRep_Builder &BB, TopoDS_Shape &target, ...@@ -652,7 +646,7 @@ void OCC_Connect::Intersect(BRep_Builder &BB, TopoDS_Shape &target,
BRepExtrema_ExtPC distance(vertex,edge); BRepExtrema_ExtPC distance(vertex,edge);
if(!distance.IsDone()) if(!distance.IsDone())
continue; continue;
double tolerance=max(BRep_Tool::Tolerance(edge), double tolerance=std::max(BRep_Tool::Tolerance(edge),
BRep_Tool::Tolerance(vertex)); BRep_Tool::Tolerance(vertex));
for(int i=1;i<=distance.NbExt();i++) { for(int i=1;i<=distance.NbExt();i++) {
if(distance.Value(i)<tolerance) { if(distance.Value(i)<tolerance) {
......
...@@ -8,7 +8,7 @@ include variables ...@@ -8,7 +8,7 @@ include variables
GMSH_MAJOR_VERSION = 2 GMSH_MAJOR_VERSION = 2
GMSH_MINOR_VERSION = 3 GMSH_MINOR_VERSION = 3
GMSH_PATCH_VERSION = 1 GMSH_PATCH_VERSION = 1
GMSH_EXTRA_VERSION = GMSH_EXTRA_VERSION = "-cvs-20090520"
GMSH_VERSION =\ GMSH_VERSION =\
${GMSH_MAJOR_VERSION}.${GMSH_MINOR_VERSION}.${GMSH_PATCH_VERSION}${GMSH_EXTRA_VERSION} ${GMSH_MAJOR_VERSION}.${GMSH_MINOR_VERSION}.${GMSH_PATCH_VERSION}${GMSH_EXTRA_VERSION}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment