Adapt to new QuadSet implementation.
authormtadel <mtadel@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 17 Nov 2006 12:08:09 +0000 (12:08 +0000)
committermtadel <mtadel@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 17 Nov 2006 12:08:09 +0000 (12:08 +0000)
EVE/macros/reve_quad_test.C

index 1512470..414c5d4 100644 (file)
@@ -2,8 +2,19 @@
 
 void reve_quad_test()
 {
-  Alieve::ITSModule* qs = new Alieve::ITSModule("QuadSet Test");
-  qs->Test(200);
-  gReve->AddRenderElement(qs);
-  gReve->DrawRenderElement(qs);
+  TRandom r(0);
+
+  gStyle->SetPalette(1, 0);
+
+  Reve::QuadSet* q = new Reve::QuadSet("Pepe");
+  q->Reset(Reve::QuadSet::QT_AxisAligned, kFALSE, 32);
+  for (Int_t i=0; i<128; ++i) {
+    q->AddQuad(r.Uniform(-10, 10), r.Uniform(-10, 10), r.Uniform(-10, 10),
+              r.Uniform(-1, 1), r.Uniform(-1, 1));
+    q->QuadValue(r.Uniform(0, 130));
+  }
+  q->RefitPlex();
+
+  gReve->AddRenderElement(q);
+  gReve->Redraw3D();
 }