diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-02-25 20:04:03 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-02-25 20:04:03 +0400 |
commit | 6ca7d8293228e821695a3149e8fb91b0d305daeb (patch) | |
tree | 05443cd06956fd844d73f333aea5d388f5d22efb /intern/boolop | |
parent | 05725e7b6ef4ee65ff7d9886b32a60c3e620d1c9 (diff) |
code cleanup: white space, spelling & ';;' end of lines.
Diffstat (limited to 'intern/boolop')
-rw-r--r-- | intern/boolop/intern/BOP_BSPNode.cpp | 4 | ||||
-rw-r--r-- | intern/boolop/intern/BOP_Face2Face.cpp | 30 | ||||
-rw-r--r-- | intern/boolop/intern/BOP_Merge2.h | 2 | ||||
-rw-r--r-- | intern/boolop/intern/BOP_Mesh.cpp | 14 | ||||
-rw-r--r-- | intern/boolop/intern/BOP_Mesh.h | 2 |
5 files changed, 26 insertions, 26 deletions
diff --git a/intern/boolop/intern/BOP_BSPNode.cpp b/intern/boolop/intern/BOP_BSPNode.cpp index 7d9071b3132..3588e80c28e 100644 --- a/intern/boolop/intern/BOP_BSPNode.cpp +++ b/intern/boolop/intern/BOP_BSPNode.cpp @@ -89,10 +89,10 @@ unsigned int BOP_BSPNode::addFace(const BOP_BSPPoints& pts, else { m_outChild = new BOP_BSPNode(plane); newDeep = 2; - } + } } else { // face lies in both half-spaces: split it BOP_BSPPoints inside, outside; - MT_Point3 lpoint= pts[pts.size()-1]; + MT_Point3 lpoint= pts[pts.size()-1]; BOP_TAG ltag = testPoint(lpoint); BOP_TAG tstate = ltag; diff --git a/intern/boolop/intern/BOP_Face2Face.cpp b/intern/boolop/intern/BOP_Face2Face.cpp index de9fa7b8508..f88a271bfdb 100644 --- a/intern/boolop/intern/BOP_Face2Face.cpp +++ b/intern/boolop/intern/BOP_Face2Face.cpp @@ -538,10 +538,10 @@ void BOP_mergeSort(MT_Point3 *points, unsigned int *face, unsigned int &size, bo for(i=0;i<size;i++) { if (position[i] == 1) { invertA = true; - break; - } - else if (position[i] == 0) break; - } + break; + } + else if (position[i] == 0) break; + } // invertBø? if (size == 4) { @@ -597,7 +597,7 @@ void BOP_mergeSort(MT_Point3 *points, unsigned int *face, unsigned int &size, bo sortedFaces[i] = sortedFaces[i+1]; } size--; - } + } } else { // merge 0 and 1 @@ -616,7 +616,7 @@ void BOP_mergeSort(MT_Point3 *points, unsigned int *face, unsigned int &size, bo size--; } } - } + } } else { if (BOP_fuzzyZero(d2) && sortedFaces[1] != sortedFaces[2]) { @@ -637,14 +637,14 @@ void BOP_mergeSort(MT_Point3 *points, unsigned int *face, unsigned int &size, bo } } } - + // Merge initial points ... for(i=0;i<size;i++) { points[i] = sortedPoints[i]; face[i] = sortedFaces[i]; } - } + } } @@ -1058,17 +1058,17 @@ void triangulate(BOP_Mesh *mesh, BOP_Faces *faces, BOP_Face *face, BOP_Segment s else { // EDGE(v1) + EDGE(v2) if (BOP_Segment::getEdge(s.m_cfg1) == BOP_Segment::getEdge(s.m_cfg2)) { - // EDGE(v1) == EDGE(v2) + // EDGE(v1) == EDGE(v2) BOP_Edge *edge = mesh->getEdge(face,BOP_Segment::getEdge(s.m_cfg1)); - BOP_triangulateD(mesh, faces, face, s.m_v1, s.m_v2, - BOP_Segment::getEdge(s.m_cfg1)); + BOP_triangulateD(mesh, faces, face, s.m_v1, s.m_v2, + BOP_Segment::getEdge(s.m_cfg1)); BOP_Face *opposite = BOP_getOppositeFace(mesh,faces,face,edge); if (opposite != NULL) { - unsigned int e; - opposite->getEdgeIndex(edge->getVertex1(), edge->getVertex2(),e); - BOP_triangulateD(mesh, faces, opposite, s.m_v1, s.m_v2, e); + unsigned int e; + opposite->getEdgeIndex(edge->getVertex1(), edge->getVertex2(),e); + BOP_triangulateD(mesh, faces, opposite, s.m_v1, s.m_v2, e); } - } + } else { // EDGE(v1) != EDGE(v2) BOP_Edge *edge1 = mesh->getEdge(face,BOP_Segment::getEdge(s.m_cfg1)); BOP_Edge *edge2 = mesh->getEdge(face,BOP_Segment::getEdge(s.m_cfg2)); diff --git a/intern/boolop/intern/BOP_Merge2.h b/intern/boolop/intern/BOP_Merge2.h index 1e26a2576be..71ec0702a0b 100644 --- a/intern/boolop/intern/BOP_Merge2.h +++ b/intern/boolop/intern/BOP_Merge2.h @@ -78,7 +78,7 @@ class BOP_Merge2 { BOP_Index X, BOP_Index I, BOP_Index P, BOP_Index N ); BOP_Face *find4Neighbor(BOP_Face *faceI, BOP_Face *faceJ, BOP_Index X, BOP_Index I, BOP_Index P, BOP_Index N, - BOP_Face **faceL, BOP_Index &O); + BOP_Face **faceL, BOP_Index &O); BOP_Face3 *collapse(BOP_Face4 *faceC, BOP_Index X); void mergeFaces(BOP_Face *A, BOP_Face *B, BOP_Index X, BOP_Index I, BOP_Index N, BOP_Index P, BOP_Faces &newFaces ); diff --git a/intern/boolop/intern/BOP_Mesh.cpp b/intern/boolop/intern/BOP_Mesh.cpp index e35b5437f68..673caa3e921 100644 --- a/intern/boolop/intern/BOP_Mesh.cpp +++ b/intern/boolop/intern/BOP_Mesh.cpp @@ -252,8 +252,8 @@ BOP_Index BOP_Mesh::addFace(BOP_Face3 *face) BOP_Index index2 = face->getVertex(1); BOP_Index index3 = face->getVertex(2); - m_faces.push_back((BOP_Face *)face); - + m_faces.push_back((BOP_Face *)face); + BOP_Index edge; if (!getIndexEdge(index1,index2,edge)) { @@ -261,7 +261,7 @@ BOP_Index BOP_Mesh::addFace(BOP_Face3 *face) getVertex(index1)->addEdge(edge); getVertex(index2)->addEdge(edge); } - + getEdge(edge)->addFace(indexface); if (!getIndexEdge(index2,index3,edge)) { @@ -269,7 +269,7 @@ BOP_Index BOP_Mesh::addFace(BOP_Face3 *face) getVertex(index2)->addEdge(edge); getVertex(index3)->addEdge(edge); } - + getEdge(edge)->addFace(indexface); if (!getIndexEdge(index3,index1,edge)) { @@ -277,13 +277,13 @@ BOP_Index BOP_Mesh::addFace(BOP_Face3 *face) getVertex(index3)->addEdge(edge); getVertex(index1)->addEdge(edge); } - + getEdge(edge)->addFace(indexface); if ((index1 == index2) || (index1 == index3) || (index2 == index3)) face->setTAG(BROKEN); - return indexface; + return indexface; } /** @@ -452,7 +452,7 @@ bool BOP_Mesh::getIndexEdge(BOP_Index v1, BOP_Index v2, BOP_Index &e) #ifdef HASH_PRINTF_DEBUG printf ("found edge (%d %d)\n",v1,v2); #endif - e = edge->index; + e = edge->index; #ifdef BOP_NEW_MERGE if( m_edges[e]->getUsed() == false ) { m_edges[e]->setUsed(true); diff --git a/intern/boolop/intern/BOP_Mesh.h b/intern/boolop/intern/BOP_Mesh.h index 381557ec58b..9c1b4ad04ea 100644 --- a/intern/boolop/intern/BOP_Mesh.h +++ b/intern/boolop/intern/BOP_Mesh.h @@ -100,7 +100,7 @@ public: BOP_Index replaceVertexIndex(BOP_Index oldIndex, BOP_Index newIndex); #ifdef HASH void rehashVertex(BOP_Index oldIndex, BOP_Index newIndex, - BOP_Index otherIndex); + BOP_Index otherIndex); #endif bool isClosedMesh(); |