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

fix msvc compile

parent e278ca6b
Branches
Tags
No related merge requests found
...@@ -170,7 +170,7 @@ int GModel::importGEOInternals() ...@@ -170,7 +170,7 @@ int GModel::importGEOInternals()
} }
std::list<GEdge*> b[4]; std::list<GEdge*> b[4];
for(int j = 0; j < 4; j++){ for(int j = 0; j < 4; j++){
for(int k = 0; k < s->compoundBoundary[j].size(); k++){ for(unsigned int k = 0; k < s->compoundBoundary[j].size(); k++){
GEdge *ge = getEdgeByTag(s->compoundBoundary[j][k]); GEdge *ge = getEdgeByTag(s->compoundBoundary[j][k]);
if(ge) b[j].push_back(ge); if(ge) b[j].push_back(ge);
} }
......
...@@ -890,7 +890,7 @@ int GModel::writeDistanceMSH(const std::string &name, double version, bool binar ...@@ -890,7 +890,7 @@ int GModel::writeDistanceMSH(const std::string &name, double version, bool binar
SPoint3 p3 (v3->x(),v3->y(),v3->z()); SPoint3 p3 (v3->x(),v3->y(),v3->z());
signedDistancesPointsTriangle(iDistances, iClosePts, pts, p1,p2,p3); signedDistancesPointsTriangle(iDistances, iClosePts, pts, p1,p2,p3);
} }
for (int kk = 0; kk< pts.size(); kk++) { for (unsigned int kk = 0; kk< pts.size(); kk++) {
if (std::abs(iDistances[kk]) < distances[kk] ) if (std::abs(iDistances[kk]) < distances[kk] )
distances[kk] = std::abs(iDistances[kk]); distances[kk] = std::abs(iDistances[kk]);
} }
...@@ -1026,7 +1026,7 @@ int GModel::writeDistanceMSH(const std::string &name, double version, bool binar ...@@ -1026,7 +1026,7 @@ int GModel::writeDistanceMSH(const std::string &name, double version, bool binar
dist.push_back(*(it->second)); dist.push_back(*(it->second));
} }
fprintf(f3,"){"); fprintf(f3,"){");
for (int i=0; i<dist.size(); i++){ for (unsigned int i = 0; i < dist.size(); i++){
if (i) fprintf(f3,",%g", dist[i]); if (i) fprintf(f3,",%g", dist[i]);
else fprintf(f3,"%g", dist[i]); else fprintf(f3,"%g", dist[i]);
} }
...@@ -1056,7 +1056,7 @@ int GModel::writeDistanceMSH(const std::string &name, double version, bool binar ...@@ -1056,7 +1056,7 @@ int GModel::writeDistanceMSH(const std::string &name, double version, bool binar
dist.push_back(it->second); dist.push_back(it->second);
} }
fprintf(f4,"){"); fprintf(f4,"){");
for (int i=0; i<dist.size(); i++){ for (unsigned int i = 0; i < dist.size(); i++){
if (i) fprintf(f4,",%g", dist[i]); if (i) fprintf(f4,",%g", dist[i]);
else fprintf(f4,"%g", dist[i]); else fprintf(f4,"%g", dist[i]);
} }
......
...@@ -429,7 +429,7 @@ void MElement::writeMSH(FILE *fp, double version, bool binary, int num, ...@@ -429,7 +429,7 @@ void MElement::writeMSH(FILE *fp, double version, bool binary, int num,
int blob[60] = {type, 1, numTags, num ? num : _num, abs(physical), elementary, int blob[60] = {type, 1, numTags, num ? num : _num, abs(physical), elementary,
1 + numGhosts, _partition}; 1 + numGhosts, _partition};
if(ghosts) if(ghosts)
for(unsigned int i = 0; i < numGhosts; i++) blob[8 + i] = -(*ghosts)[i]; for(int i = 0; i < numGhosts; i++) blob[8 + i] = -(*ghosts)[i];
fwrite(blob, sizeof(int), 4 + numTags, fp); fwrite(blob, sizeof(int), 4 + numTags, fp);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment