7 const Int_t paletteSize = 10;
20 Int_t palette[paletteSize] = {0};
22 for (
Int_t i = 0; i < paletteSize; ++i)
28 TCanvas *cnv =
new TCanvas(
"glc",
"Surface sample", 200, 10, 600, 550);
31 "\"glsurf2pol\" option + user defined palette.");
35 TPad *rosePad =
new TPad(
"box",
"box", 0.04, 0.04, 0.96, 0.8);
39 TF2 *fun =
new TF2(
"a",
"cos(y)*sin(x)+cos(x)*sin(y)", -6, 6, -6, 6);
44 fun->
Draw(
"glsurf2pol");
virtual void Draw(Option_t *option="")
Draw this function with its current attributes.
virtual void SetNpx(Int_t npx=100)
Set the number of points used to draw the function.
R__EXTERN TStyle * gStyle
TVirtualPad * cd(Int_t subpadnumber=0)
Set Current pad.
virtual void Draw(Option_t *option="")
Draw Pad in Current pad (re-parent pad if necessary).
void SetCanvasPreferGL(Bool_t prefer=kTRUE)
A Pave (see TPave) with a text centered in the Pave.
TPaveLabel title(3, 27.1, 15, 28.7,"ROOT Environment and Tools")
virtual void SetFillColor(Color_t fcolor)
The most important graphics class in the ROOT system.
virtual void SetNpy(Int_t npy=100)
Set the number of points used to draw the function.
static Int_t GetColor(const char *hexcolor)
Static method returning color number for color specified by hex color string of form: "#rrggbb"...
A 2-Dim function with parameters.
virtual void Draw(Option_t *option="")
Draw this pavelabel with its current attributes.
virtual void SetContour(Int_t nlevels=20, const Double_t *levels=0)
Set the number and values of contour levels.
void SetPalette(Int_t ncolors=kBird, Int_t *colors=0, Float_t alpha=1.)
See TColor::SetPalette.