Salome HOME
PR: merged from V5_1_4rc1
[modules/smesh.git] / src / DriverSTL / DriverSTL_W_SMDS_Mesh.cxx
index 8b2ed581bfee5bf73162243e4a8ff48ad04796d9..7704cf26cbc9feb375701611656fa7513da4dafd 100644 (file)
@@ -1,21 +1,24 @@
-//  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
-// 
-//  This library is free software; you can redistribute it and/or 
-//  modify it under the terms of the GNU Lesser General Public 
-//  License as published by the Free Software Foundation; either 
-//  version 2.1 of the License. 
-// 
-//  This library is distributed in the hope that it will be useful, 
-//  but WITHOUT ANY WARRANTY; without even the implied warranty of 
-//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
-//  Lesser General Public License for more details. 
-// 
-//  You should have received a copy of the GNU Lesser General Public 
-//  License along with this library; if not, write to the Free Software 
-//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA 
-// 
-// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//  Copyright (C) 2007-2010  CEA/DEN, EDF R&D, OPEN CASCADE
+//
+//  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of the GNU Lesser General Public
+//  License as published by the Free Software Foundation; either
+//  version 2.1 of the License.
+//
+//  This library is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+//  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
 
 #include <stdio.h>
 
@@ -69,7 +72,7 @@ Driver_Mesh::Status DriverSTL_W_SMDS_Mesh::Perform()
 // static methods
 
 static void writeInteger( const Standard_Integer& theVal,
-                        OSD_File& ofile )
+                         OSD_File& ofile )
 {
   union {
     Standard_Integer i;
@@ -88,7 +91,7 @@ static void writeInteger( const Standard_Integer& theVal,
 }
 
 static void writeFloat  ( const Standard_ShortReal& theVal,
-                        OSD_File& ofile)
+                         OSD_File& ofile)
 {
   union {
     Standard_ShortReal f;
@@ -177,7 +180,7 @@ Driver_Mesh::Status DriverSTL_W_SMDS_Mesh::writeAscii() const
       
       SMDS_ElemIteratorPtr aNodeIter = aFace->nodesIterator();
       for (; aNodeIter->more(); ) {
-       SMDS_MeshNode* node = (SMDS_MeshNode*)aNodeIter->next();
+        SMDS_MeshNode* node = (SMDS_MeshNode*)aNodeIter->next();
         buf += "     vertex "; 
         sprintf (sval,"% 12e",node->X());
         buf += sval;
@@ -247,10 +250,10 @@ Driver_Mesh::Status DriverSTL_W_SMDS_Mesh::writeBinary() const
 
       SMDS_ElemIteratorPtr aNodeIter = aFace->nodesIterator();
       for (; aNodeIter->more(); ) {
-       SMDS_MeshNode* node = (SMDS_MeshNode*)aNodeIter->next();
-       writeFloat(node->X(),aFile);
-       writeFloat(node->Y(),aFile);
-       writeFloat(node->Z(),aFile);
+        SMDS_MeshNode* node = (SMDS_MeshNode*)aNodeIter->next();
+        writeFloat(node->X(),aFile);
+        writeFloat(node->Y(),aFile);
+        writeFloat(node->Z(),aFile);
       }
       aFile.Write (&dum,2);
     }