← Back to team overview

yade-dev team mailing list archive

[svn] r1765 - in trunk: core pkg/lattice/PreProcessor

 

Author: cosurgi
Date: 2009-05-04 16:31:07 +0200 (Mon, 04 May 2009)
New Revision: 1765

Modified:
   trunk/core/NullGUI.cpp
   trunk/pkg/lattice/PreProcessor/LatticeExample.cpp
   trunk/pkg/lattice/PreProcessor/LatticeExample.hpp
Log:
1. NullGUI was still usin .gz while thay are not supported anymore
2. small lattice update



Modified: trunk/core/NullGUI.cpp
===================================================================
--- trunk/core/NullGUI.cpp	2009-05-04 08:38:56 UTC (rev 1764)
+++ trunk/core/NullGUI.cpp	2009-05-04 14:31:07 UTC (rev 1765)
@@ -152,7 +152,12 @@
 
 	filesystem::path p(snapshotName);
 	if(filesystem::extension(p)==".gz")
-		p = filesystem::basename(p); // get rid of .gz
+	{
+		std::cerr << "Error: .gz is no longer supported, use .bz2 instead.";
+		exit(1);
+	}
+	if(filesystem::extension(p)==".bz2")
+		p = filesystem::basename(p); // get rid of .bz2
 	snapshotName = filesystem::basename(p); // get rid of .xml
 	if( snapshotInterval != -1 )
 		cerr 	<< "Saving snapshot every " << snapshotInterval*interval << " iterations, \n"
@@ -182,7 +187,7 @@
 			//		+ "__dt_" + lexical_cast<string>(Omega::instance().getTimeStep())
 			//		+ "__it_" + lexical_cast<string>(Omega::instance().getCurrentIteration()) 
 					+ "_" + lexical_cast<string>(Omega::instance().getCurrentIteration()) 
-					+ (binary?".xml.gz":".xml");
+					+ (binary?".xml.bz2":".xml");
 				cerr << "saving snapshot: " << fileName << "   ...";
 				Omega::instance().saveSimulation(fileName);
 				cerr << " done.\n";
@@ -230,7 +235,7 @@
 	if(snapshotName=="none")
 		std::cerr << "filegenerator output name set to \"none\" - using default output name.\n";
 	else
-		f->setFileName(snapshotName + (binary?".xml.gz":".xml"));
+		f->setFileName(snapshotName + (binary?".xml.bz2":".xml"));
 	std::cerr	<< "calling FileGenerator: " << filegen 
 			<< ",\nwith config file: " << file 
 			<< ",\nto generate file: " << f->getFileName() << "\n\n";

Modified: trunk/pkg/lattice/PreProcessor/LatticeExample.cpp
===================================================================
--- trunk/pkg/lattice/PreProcessor/LatticeExample.cpp	2009-05-04 08:38:56 UTC (rev 1764)
+++ trunk/pkg/lattice/PreProcessor/LatticeExample.cpp	2009-05-04 14:31:07 UTC (rev 1765)
@@ -86,7 +86,7 @@
         
         ensure2D 		 = false;
         roughEdges 		 = false;
-	calculate_Torsion	 = false;
+	calculate_Torsion_3D	 = false;
 	quads			 = false;
         
         region_A_min             = Vector3r(-0.006, 0.096,-1);
@@ -278,7 +278,7 @@
         
         REGISTER_ATTRIBUTE(ensure2D);
         REGISTER_ATTRIBUTE(roughEdges);
-        REGISTER_ATTRIBUTE(calculate_Torsion);
+        REGISTER_ATTRIBUTE(calculate_Torsion_3D);
         REGISTER_ATTRIBUTE(quads);
         
         REGISTER_ATTRIBUTE(triangularBaseGrid);         //              - triangles
@@ -1192,7 +1192,7 @@
 	shared_ptr<LatticeLaw> latticeLaw(new LatticeLaw);
         latticeLaw->ensure2D   = ensure2D;
         latticeLaw->roughEdges = roughEdges;
-        latticeLaw->calcTorsion= calculate_Torsion;
+        latticeLaw->calcTorsion= calculate_Torsion_3D;
 	latticeLaw->tension_compression_different_stiffness = true;	
         
         rootBody->engines.clear();

Modified: trunk/pkg/lattice/PreProcessor/LatticeExample.hpp
===================================================================
--- trunk/pkg/lattice/PreProcessor/LatticeExample.hpp	2009-05-04 08:38:56 UTC (rev 1764)
+++ trunk/pkg/lattice/PreProcessor/LatticeExample.hpp	2009-05-04 14:31:07 UTC (rev 1765)
@@ -50,7 +50,7 @@
                                 ,useStiffnessSoftening
                                 ,ensure2D
                                 ,roughEdges
-				,calculate_Torsion
+				,calculate_Torsion_3D
 				,quads;
         
         // aggregates