0031939: Coding - correction of spelling errors in comments [part 10]
[occt.git] / src / ShapeFix / ShapeFix_Shell.cxx
index 83f54f1..fb8cd9b 100644 (file)
@@ -367,7 +367,7 @@ static Standard_Boolean AddMultiConexityFaces(TopTools_SequenceOfShape& Lface,
     }
   }
   
-  // Attemp to create shell from unconnected which have not only multiconnexity boundary.
+  // Attempt to create shell from unconnected which have not only multiconnexity boundary.
   TopTools_SequenceOfShape aTmpShells;
   if(!llPosibleShells.IsEmpty()) {
     TopTools_MapOfShape aMap;
@@ -390,7 +390,7 @@ static Standard_Boolean AddMultiConexityFaces(TopTools_SequenceOfShape& Lface,
     }
   }
   
-  //Add choosen faces to shells.
+  //Add chosen faces to shells.
   for(Standard_Integer k1 =1; k1 <= AddShapes.Length(); k1++) {
     TopTools_DataMapOfShapeInteger MapOtherShells;
     TopTools_MapOfShape dire,reve;
@@ -452,7 +452,7 @@ static Standard_Boolean AddMultiConexityFaces(TopTools_SequenceOfShape& Lface,
       continue;
     }
     
-    //Adds face to open shells containg the same multishared edges.
+    //Adds face to open shells containing the same multishared edges.
     //For nonmanifold mode creation ine shell from face and shells containing the same multishared edges.
     // If one face can be added to a few shells (case of compsolid) face will be added to each shell.
     done = Standard_True;
@@ -552,12 +552,11 @@ static void GetClosedShells(TopTools_SequenceOfShape& Shells, TopTools_SequenceO
 }
 //=======================================================================
 // function : GlueClosedCandidate
-// purpose  :Attemt firstly to create closed shells from sequence of open shells.
+// purpose  : First, attempt to create closed shells from sequence of open shells.
 //=======================================================================
 static void GlueClosedCandidate(TopTools_SequenceOfShape& OpenShells,
                                                     const TopTools_MapOfShape& aMapMultiConnectEdges,
                                                     TopTools_SequenceOfShape& aSeqNewShells)
-                                                    
 {
   // Creating new shells if some open shells contain the same free boundary.
   for(Standard_Integer i = 1 ; i < OpenShells.Length();i++ )  {
@@ -597,13 +596,12 @@ static void GlueClosedCandidate(TopTools_SequenceOfShape& OpenShells,
           isReversed = Standard_True;
         nbedge++;
       }
-      
+
       if(!isAddShell) continue;
       MapOtherShells.Bind(OpenShells.Value(j),isReversed);
     }
     if(MapOtherShells.IsEmpty()) continue;
-    
-    
+
     if (!MapOtherShells.IsEmpty())
     {
       // Case of compsolid when more than two shells have the same free boundary.
@@ -615,8 +613,8 @@ static void GlueClosedCandidate(TopTools_SequenceOfShape& OpenShells,
         aSeqCandidate.Append(aIt.Key());
       }
       
-      //Creation all possibly shells from choosen candidate.And
-      // addition of them to temporary sequence.
+      //Creation of all possible shells from chosen candidate.
+      // And the addition of them to temporary sequence.
       
       TopTools_SequenceOfShape aTmpSeq;
       for(Standard_Integer k =1; k <= aSeqCandidate.Length(); k++) {
@@ -638,7 +636,7 @@ static void GlueClosedCandidate(TopTools_SequenceOfShape& OpenShells,
           aTmpSeq.Append(aNewSh);
         }
       }
-      
+
       //Choice from temporary sequence shells contains different set of faces (case of compsolid) 
       TopTools_SequenceOfShape aRemainShells;
       GetClosedShells(aTmpSeq,aRemainShells);
@@ -796,9 +794,9 @@ static void CreateClosedShell(TopTools_SequenceOfShape& OpenShells,
                               const TopTools_MapOfShape& aMapMultiConnectEdges)
 {
   TopTools_SequenceOfShape aNewShells;
-  //Attemt firstly to create closed shells.
+  //First, attempt to create closed shells.
   GlueClosedCandidate(OpenShells,aMapMultiConnectEdges,aNewShells);
-  
+
   // Creating new shells if some open shells contain the multishared same edges.
   for(Standard_Integer i = 1 ; i < OpenShells.Length();i++ )  {
     Standard_Boolean isAddShell = Standard_False;
@@ -827,32 +825,32 @@ static void CreateClosedShell(TopTools_SequenceOfShape& OpenShells,
            || (edge2.Orientation() == TopAbs_REVERSED && reve.Contains(edge2)))
           isReversed = Standard_True;
       }
-      
+
       if(!isAddShell) continue;
       BRep_Builder aB;
-      
+
       for(TopExp_Explorer aExpF21(OpenShells.Value(j),TopAbs_FACE); aExpF21.More(); aExpF21.Next()) {
         TopoDS_Shape aFace = aExpF21.Current();
         if(isReversed)
           aFace.Reverse();
         aB.Add( aShell,aFace);
       }
-      
+
       OpenShells.ChangeValue(i) = aShell;
       OpenShells.Remove(j--);
     }
   }
+
   OpenShells.Append(aNewShells);
-  
+
 }
-  
+
 
 //=======================================================================
 // function : FixFaceOrientation
 // purpose  : 
 //=======================================================================
-  
+
 Standard_Boolean ShapeFix_Shell::FixFaceOrientation(
     const TopoDS_Shell& shell,
     const Standard_Boolean isAccountMultiConex,