https://github.com/root-project/root
Raw File
Tip revision: 679d22edaa69a6b84ae1b5efbd5b145c93a86c4e authored by Unknown Author on 10 February 2005, 07:32:28 UTC
This commit was manufactured by cvs2svn to create tag 'v4-03-02'.
Tip revision: 679d22e
imgconv.C
void imgconv()
{
   // Open rose512.jpg and save it in the following formats:
   //  .png, .gif, .xpm and tiff.

   TImage *img = TImage::Open("rose512.jpg");
   if (!img) {
      printf("Could not create an image... exit\n");
      return;
   }

   img->WriteImage("rose512.png");
   img->WriteImage("rose512.gif");
   img->WriteImage("rose512.xpm");
   img->WriteImage("rose512.tiff");
}
back to top