Hi,
you can switch to the batch mode before printing and when switch back
gROOT->SetBatch(kTRUE);
Csec->Print("test.gif");
gROOT->SetBatch(kFALSE);
HTH. Regards. Valeriy
-----Исходное сообщение-----
От: owner-roottalk_at_root.cern.ch от имени Stefan Piperov
Отправлено: Пт, 4/16/2010 8:52
Кому: xsatya_at_gmail.com
Копия: roottalk; roottalk (Mailing list discussing all aspects of the ROOT system.)
Тема: Re: [ROOT] Error Creating GIF image
Save as JPEG and then convert the image to GIF outside of ROOT. GIF format is known to have some limitations (256 colors) and problems (patent issues, which are largely resolved now, but still..)
Or perhaps you can use PNG format? That's more universal these days.
Of course the best practice is to save as Encapsulated Postscript (vector graphics), and then convert to bitmaps (JPEG, PNG, GIF) whenever you need a specific representation of your plot. This way you never lose any resolution, and are also able to make minor changes to the plot outside ROOT - like changing axis names, or labels.
Cheers,
Stefan.
On Fri, 16 Apr 2010, xsatya wrote:
> Hello,
>
> I am getting an error
>
> Error in <TGX11TTF::WriteGIF>: can not create GIF of image containing more
> than 256 colors
>
> root: ROOT 5.26/00 (tags/v5-26-00_at_31883
> Linux 2.6.18-164.2.1.el5PAE #1 SMP Tue Sep 29 19:14:47 EDT 2009 i686 i686
> i386 GNU/Linux
>
> I show in root, but couldn't get proper answer
> http://root.cern.ch/phpBB2/viewtopic.php?p=6633&sid=866b2363f681efd79583a7be9fc51529
>
> Could you please suggest what to do.
>
> Regards,
> S
> --
> ---------------
> Research Student,
> High Energy Physics, India.
>
*---------------------------------------------------------------------* Stefan Piperov Mail: FNAL P.O.Box 500, MS 205, Batavia, IL-60510 Phone: (630) 840-5176 E-Mail: piperov_at_fnal.gov *---------------------------------------------------------------------*"Give a skeptic an inch... and he'll measure it." Received on Mon Apr 26 2010 - 13:34:03 CEST
This archive was generated by hypermail 2.2.0 : Mon Apr 26 2010 - 23:50:01 CEST