Hi Adam, //example of new colors (greys) and definition of a new palette void palette() { const Int_t colNum = 100; Int_t palette[colNum]; for (Int_t i=0;i<colNum;i++) { TColor *color = new TColor(501+i ,1-Float_t(i)/colNum ,1-Float_t(i)/colNum ,1-Float_t(i)/colNum,""); palette[i] = 501+i; } gStyle->SetPalette(colNum,palette); TF2 *f2 = new TF2("f2","exp(-(x^2) - (y^2))",-1.5,1.5,-1.5,1.5); f2->SetContour(colNum); f2->Draw("contz"); } Rene Brun On Mon, 13 Aug 2001, Adam Bouchta wrote: > > Hello, > > I wonder how one can expand the number of gray-levels in the palette? For > the moment I just limit the number of colors to 9 and get that number of > grays. How can one get 100 or so levels? > > Thanks, > > Adam. >
This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:57 MET