ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
gldemos.C
Go to the documentation of this file.
1 // Menu for running GL demos.
2 // Author: Timur Pocheptsov
3 void gldemos()
4 {
5  TControlBar *bar = new TControlBar("vertical", "GL painter demo",20,20);
6  bar->AddButton("Help on demos", "help()", "Description");
7  bar->AddButton("glsurfaces", ".x $ROOTSYS/tutorials/gl/glsurfaces.C", "Surface painter example");
8  bar->AddButton("glrose", ".x $ROOTSYS/tutorials/gl/glrose.C", "Surface in polar system");
9  bar->AddButton("gltf3", ".x $ROOTSYS/tutorials/gl/gltf3.C", "TF3 painter");
10  bar->AddButton("glbox", ".x $ROOTSYS/tutorials/gl/glbox.C", "BOX painter");
11  bar->AddButton("glparametric", ".x $ROOTSYS/tutorials/gl/glparametric.C", "Parametric surface");
12  bar->Show();
13 }
14 
15 void help()
16 {
17  new TCanvas("chelp","Help on gldemos",200,10,700,600);
18 
19  TPaveLabel *title = new TPaveLabel(0.04, 0.86, 0.96, 0.98, "These demos show different gl painters.");
20  title->SetFillColor(32);
21  title->Draw();
22 
23  TPaveText *hdemo = new TPaveText(0.04, 0.04, 0.96, 0.8);
24  hdemo->SetTextAlign(12);
25  hdemo->SetTextFont(52);
26  hdemo->SetTextColor(kBlue);
27  hdemo->AddText("1. Glsurfaces demo shows glsurf4, glsurf1, glsurf3, glsurf1cyl, glsurfpol, gltf3 options.");
28  hdemo->AddText("2. Glrose demontrates \"glsurf2pol\" drawing option and user-defined palette.");
29  hdemo->AddText("3. Gltf3 demo shows \"gltf3\" option.");
30  hdemo->AddText("4. Glbox demo shows \"glbox\" and \"glbox1\" options for TH3.");
31  hdemo->AddText("5. Glparametric demo shows how to define and display parametric surfaces.");
32  hdemo->AddText("You can zoom any plot: press 'J', 'K', 'j', 'k' keys, or use mouse wheel.");
33  hdemo->AddText("Rotate any plot:");
34  hdemo->AddText(" ---select plot with mouse cursor,");
35  hdemo->AddText(" ---move mouse cursor, pressing and holding left mouse button ");
36  hdemo->AddText("Pan plot:");
37  hdemo->AddText(" ---select with mouse cursor a part of a plot, other than back box planes ,");
38  hdemo->AddText(" ---move mouse cursor, pressing and holding middle mouse button ");
39  hdemo->AddText("Selected part of a plot is higlighted (TF3 higlighting is not implemented yet.)");
40  hdemo->AddText("You can select one of back box planes, press middle mouse button and move cursor-");
41  hdemo->AddText("this will create \"slice\" (TF does not support yet).");
42  hdemo->AddText("After the slice was created, you can project it on a back box");
43  hdemo->AddText(" ---press key 'p' (now implemented only for surf options ).");
44  hdemo->AddText("Left double click removes all slices/projections.");
45 
46  hdemo->Draw();
47 
48 }
TControlBar * bar
Definition: demos.C:15
void Show()
Show control bar.
void AddButton(TControlBarButton *button)
Add button.
A Control Bar is a fully user configurable tool which provides fast access to frequently used operati...
Definition: TControlBar.h:37
virtual void Draw(Option_t *option="")
Draw this pavetext with its current attributes.
Definition: TPaveText.cxx:211
virtual TText * AddText(Double_t x1, Double_t y1, const char *label)
Add a new Text line to this pavetext at given coordinates.
Definition: TPaveText.cxx:160
virtual void SetTextFont(Font_t tfont=62)
Definition: TAttText.h:59
void gldemos()
Definition: gldemos.C:3
virtual void SetTextAlign(Short_t align=11)
Definition: TAttText.h:55
A Pave (see TPave) with a text centered in the Pave.
Definition: TPaveLabel.h:32
TPaveLabel title(3, 27.1, 15, 28.7,"ROOT Environment and Tools")
virtual void SetFillColor(Color_t fcolor)
Definition: TAttFill.h:50
The Canvas class.
Definition: TCanvas.h:48
A Pave (see TPave) with text, lines or/and boxes inside.
Definition: TPaveText.h:35
virtual void Draw(Option_t *option="")
Draw this pavelabel with its current attributes.
Definition: TPaveLabel.cxx:77
virtual void SetTextColor(Color_t tcolor=1)
Definition: TAttText.h:57
Definition: Rtypes.h:61
void help()
Definition: gldemos.C:15