https://github.com/root-project/root
Revision bd13c26481b2e4cbbc783eee6cf30dcd9c47cf47 authored by Sergey Linev on 18 June 2015, 07:45:21 UTC, committed by Bertrand Bellenot on 18 June 2015, 13:25:00 UTC
Signed-off-by: Bertrand Bellenot <bertrand.bellenot@cern.ch>
1 parent d7e6577
Raw File
Tip revision: bd13c26481b2e4cbbc783eee6cf30dcd9c47cf47 authored by Sergey Linev on 18 June 2015, 07:45:21 UTC
jsroot: change date tag in version string
Tip revision: bd13c26
glplot.C
// Preliminary demo for showing Timur's GL plots in EVE.
// Author: Matevz Tadel, July 2009

void glplot()
{
   TEveManager::Create();
   gEve->GetDefaultGLViewer()->SetCurrentCamera(TGLViewer::kCameraPerspXOY);

   TF2 *f2 = new TF2("f2","x**2 + y**2 - x**3 -8*x*y**4", -1., 1.2, -1.5, 1.5);
   f2->SetFillColor(45);
   x = new TEvePlot3D("EvePlot - TF2");
   x->SetLogZ(kTRUE);
   x->SetPlot(f2,"glsurf4");
   x->RefMainTrans().MoveLF(2, 1);
   gEve->AddElement(x);


   TH3F *h31 = new TH3F("h31", "h31", 10, -1, 1, 10, -1, 1, 10, -1, 1);
   h31->FillRandom("gaus");
   h31->SetFillColor(2);
   x = new TEvePlot3D("EvePlot - TH3F");
   x->SetPlot(h31, "glbox");
   x->RefMainTrans().MoveLF(2, -1);
   gEve->AddElement(x);

   gEve->Redraw3D(kTRUE);
}
back to top