From 8872aa8ea21e18a947bf70f40be7821323deb34a Mon Sep 17 00:00:00 2001 From: Christophe Geuzaine <cgeuzaine@ulg.ac.be> Date: Wed, 1 Aug 2001 19:38:12 +0000 Subject: [PATCH] *** empty log message *** --- benchmarks/misc/500views.geo | 10 ++++++++++ benchmarks/misc/animation.geo | 24 ++++++++++++++++++++++++ benchmarks/misc/lists.geo | 26 ++++++++++++++++++++++++++ benchmarks/misc/loop.geo | 10 ++++++++++ benchmarks/misc/strings.geo | 18 ++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 benchmarks/misc/500views.geo create mode 100644 benchmarks/misc/animation.geo create mode 100644 benchmarks/misc/lists.geo create mode 100644 benchmarks/misc/loop.geo create mode 100644 benchmarks/misc/strings.geo diff --git a/benchmarks/misc/500views.geo b/benchmarks/misc/500views.geo new file mode 100644 index 0000000000..5da7a5873e --- /dev/null +++ b/benchmarks/misc/500views.geo @@ -0,0 +1,10 @@ + +// this tests that we can still load as many views as we want. +// (even if only 200 are allowed in the GUI) + +For i In {0:250} + +Include "../../tutorial/view1.pos" ; +Include "../../tutorial/view2.pos" ; + +EndFor diff --git a/benchmarks/misc/animation.geo b/benchmarks/misc/animation.geo new file mode 100644 index 0000000000..a97770746b --- /dev/null +++ b/benchmarks/misc/animation.geo @@ -0,0 +1,24 @@ + +General.Trackball = 0; +General.RotationX = 0 ; +General.Color.Background = White ; +General.Color.Foreground = Red ; + +View[0].IntervalsType = 2 ; +View[0].RaiseZ = 0.1 ; + +For(1:300) + + General.RotationX += 10 ; + General.RotationY = General.RotationX / 3 ; + + View[0].TimeStep += + (View[0].TimeStep < View[0].NbTimeStep-1) ? 1 : 0 ; + + View[0].RaiseZ -= .01 ; + + Sleep 0.1; + Draw; + +EndFor + diff --git a/benchmarks/misc/lists.geo b/benchmarks/misc/lists.geo new file mode 100644 index 0000000000..00ec8b0bd7 --- /dev/null +++ b/benchmarks/misc/lists.geo @@ -0,0 +1,26 @@ + +a = 1; + +Printf("a = %g", a); + +b[] = {1,2,3}; + +Printf("b = %g %g %g", b[{0:1}]); + +Printf("b[a] = %g", b[a]); + +Printf("b[b[0]] = %g", b[b[0]]); + +c[{1,2,3}] = {5,6,7} ; + +c[0] = 4 ; + +Printf("c = %g %g %g %g", c[]); + +c[{0:3}] = {-1,-2,-3,-4} ; + +Printf("c = %g %g %g %g", c[]); + +c[{b[]}] = {8,9,10} ; + +Printf("c = %g %g %g %g", c[]); diff --git a/benchmarks/misc/loop.geo b/benchmarks/misc/loop.geo new file mode 100644 index 0000000000..c6180d2cf1 --- /dev/null +++ b/benchmarks/misc/loop.geo @@ -0,0 +1,10 @@ +/* +This is a very simple control sequense +with 2 imbricated loops +*/ + +For t In {0:1:0.1} + For x In {0:0.5:0.1} + Point(newp) = {t,x,0,.1}; + EndFor +EndFor diff --git a/benchmarks/misc/strings.geo b/benchmarks/misc/strings.geo new file mode 100644 index 0000000000..bb5dd36265 --- /dev/null +++ b/benchmarks/misc/strings.geo @@ -0,0 +1,18 @@ + + +Include "../../tutorial/view1.pos" ; + +View[0].Name = "gloups.prout" ; + +General.Trackball = 0 ; + +For num In {1:2} + + General.RotationX += 10 ; + + Print StrCat( StrPrefix(Sprintf(View[0].Name)) , Sprintf("-%g.jpg", num) ) ; + + Draw ; + +EndFor + -- GitLab