← Back to team overview

yade-dev team mailing list archive

[Branch ~yade-dev/yade/trunk] Rev 2250: 1. Fix timestepper selection

 

------------------------------------------------------------
revno: 2250
fixes bug(s): https://launchpad.net/bugs/584986
committer: Václav Šmilauer <eudoxos@xxxxxxxx>
branch nick: trunk
timestamp: Mon 2010-05-24 23:14:57 +0200
message:
  1. Fix timestepper selection
  2. Disable debuggin in Eigen (for higher performance with debug builds)
modified:
  doc/sphinx/conf.py
  gui/qt3/QtGeneratedSimulationController.ui
  gui/qt3/SimulationController.cpp
  gui/qt3/SimulationController.hpp
  lib/base/Math.hpp


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'doc/sphinx/conf.py'
--- doc/sphinx/conf.py	2010-05-18 10:28:02 +0000
+++ doc/sphinx/conf.py	2010-05-24 21:14:57 +0000
@@ -370,7 +370,7 @@
 inheritance_edge_attrs = {} 
 
 my_latex_preamble=r'''
-\usepackage{euler}
+\usepackage{euler} % must be loaded before fontspec for the whole doc (below); this must be kept for pngmath, however
 \usepackage{amsmath}
 \usepackage{amsbsy}
 \let\mat\boldsymbol
@@ -525,7 +525,11 @@
 
 latex_elements=dict(
 	papersize='a4paper',
-	fontpkg='\\usepackage{fontspec,xunicode,xltxtra}\setmainfont[BoldFont={LMRoman10 Bold}]{CMU Concrete}',
+	fontpkg=r'''
+		\usepackage{euler}
+		\usepackage{fontspec,xunicode,xltxtra}
+		\setmainfont[BoldFont={LMRoman10 Bold}]{CMU Concrete}
+	''',
 	utf8extra='',
 	fncychap='',
 	preamble=my_latex_preamble,

=== modified file 'gui/qt3/QtGeneratedSimulationController.ui'
--- gui/qt3/QtGeneratedSimulationController.ui	2010-05-02 16:02:29 +0000
+++ gui/qt3/QtGeneratedSimulationController.ui	2010-05-24 21:14:57 +0000
@@ -892,7 +892,28 @@
         <receiver>QtGeneratedSimulationController</receiver>
         <slot>pbGenerate_clicked()</slot>
     </connection>
+    <connection>
+        <sender>rbFixed</sender>
+        <signal>clicked()</signal>
+        <receiver>QtGeneratedSimulationController</receiver>
+        <slot>rbFixedClicked()</slot>
+    </connection>
+    <connection>
+        <sender>rbTimeStepper</sender>
+        <signal>clicked()</signal>
+        <receiver>QtGeneratedSimulationController</receiver>
+        <slot>rbTimeStepperClicked()</slot>
+    </connection>
+    <connection>
+        <sender>leTimestep</sender>
+        <signal>returnPressed()</signal>
+        <receiver>QtGeneratedSimulationController</receiver>
+        <slot>leTimestep_returnPressed()</slot>
+    </connection>
 </connections>
+<includes>
+    <include location="local" impldecl="in implementation">QtGeneratedSimulationController.ui.h</include>
+</includes>
 <forwards>
     <forward>class GLViewer;</forward>
 </forwards>
@@ -923,6 +944,8 @@
     <slot>pyOnelinerEnter()</slot>
     <slot>pbGenerate_clicked()</slot>
     <slot>leTimestep_returnPressed()</slot>
+    <slot>rbFixedClicked()</slot>
+    <slot>rbTimeStepperClicked()</slot>
 </slots>
 <layoutdefaults spacing="6" margin="11"/>
 </UI>

=== modified file 'gui/qt3/SimulationController.cpp'
--- gui/qt3/SimulationController.cpp	2010-05-13 20:19:38 +0000
+++ gui/qt3/SimulationController.cpp	2010-05-24 21:14:57 +0000
@@ -317,34 +317,16 @@
 }
 
 
-
-
-
-
-void SimulationController::bgTimeStepClicked(int i)
-{
-	// cerr<<"CHANGING TIME STEP: i="<<i<<endl;
-	/* i: buttonGroupId, which is 0 for timeStepper, 2 for fixed step */
-	switch (i)
-	{
-		case 0 : {//Use timeStepper
-			wasUsingTimeStepper=true;
-			Omega::instance().getScene()->timeStepperActivate(true);
-			break;
-			}
-		case 1 : // Try RealTime -- deprecated
-			throw logic_error("RealTime timestep is deprecated and you couldn't click on it!");
-			break;
-		case 2 : {// use fixed time Step
-			changeTimeStep = true;
-			wasUsingTimeStepper=false;
-			Omega::instance().getScene()->timeStepperActivate(false);
-			leTimestep_returnPressed();
-			break;
-		}
-		default: break;
-	}
-
+void SimulationController::rbTimeStepperClicked(){
+	wasUsingTimeStepper=true;
+	Omega::instance().getScene()->timeStepperActivate(true);
+}
+
+void SimulationController::rbFixedClicked(){
+	changeTimeStep = true;
+	wasUsingTimeStepper=false;
+	Omega::instance().getScene()->timeStepperActivate(false);
+	leTimestep_returnPressed();
 }
 
 

=== modified file 'gui/qt3/SimulationController.hpp'
--- gui/qt3/SimulationController.hpp	2010-04-25 11:58:30 +0000
+++ gui/qt3/SimulationController.hpp	2010-05-24 21:14:57 +0000
@@ -73,7 +73,8 @@
 		virtual void pbReferenceClicked();
 		virtual void pbCenterSceneClicked();
 		virtual void pbOneSimulationStepClicked();
-		virtual void bgTimeStepClicked(int i);
+		virtual void rbFixedClicked();
+		virtual void rbTimeStepperClicked();
 		virtual void sbRefreshValueChanged(int);
 		virtual void cbSyncToggled(bool);
 		virtual void pbStart2Clicked();

=== modified file 'lib/base/Math.hpp'
--- lib/base/Math.hpp	2010-05-14 14:27:11 +0000
+++ lib/base/Math.hpp	2010-05-24 21:14:57 +0000
@@ -28,6 +28,7 @@
 	#define EIGEN_DONT_VECTORIZE
 	#define EIGEN_DONT_ALIGN
 	#define EIGEN_DISABLE_UNALIGNED_ARRAY_ASSERT
+	#define EIGEN_NO_DEBUG
 		#include<Eigen/Core>
 		#include<Eigen/Geometry>
 		#include<Eigen/Array>