Re: FW: pb Save canvas in jpg or gif format with v4.04

From: Alexis Cothenet <cothenet_at_cppm.in2p3.fr>
Date: Mon, 2 May 2005 14:57:05 +0200 (CEST)

Hi Valery,

It works! Thank you very much.

Best regards,
Alexis

On Mon, 2 May 2005, Valeriy Onuchin wrote:

> Hi Alexis,
> this is "tiny" syncronisation effect.
> To fix it try this one
>
> {
> TCanvas * newcanvas = new TCanvas("newcanvas","newcanvas",710,10,700,500);
> gVirtualX->Update(1); // <--- syncronize X server
> cout<<"for gif"<<endl;
> newcanvas->SaveAs("spectrum.gif");
> cout<<"for jpg"<<endl;
> newcanvas->SaveAs("spectrum.jpg");
> }
>
> I'll add correspondent mods to the ROOT code.
> Thanks for reporting it.
>
> Regards. Valeriy
>
> Alexis Cothenet wrote:
>
> > Hi Olivier,
> >
> > ok that's strange. Have you got a suggestion to test ?
> > If i set root v4.03 the simple macro works for .gif format but not .jpg...
> >
> > Alexis
> >
> > On Mon, 2 May 2005, Olivier Couet wrote:
> >
> > >
> > >
> > > (Sorry, I did not send my answer to roottalk here it is:)
> > >
> > > Hi Alexis,
> > >
> > > I just tried it (4.04) on cygwin. For me it works, both in interactive
> > > mode and in batch mode (root -b).
> > >
> > > Cheers, Olivier
> > >
> > >
> > > --
> > > Org: CERN - European Laboratory for Particle Physics.
> > > Mail: 1211 Geneve 23 - Switzerland Mailbox: J25910
> > >
> > > E-Mail: Olivier.Couet_at_cern.ch Phone: +41 22
> > > 7676522
> > > WWW: http://cern.ch/Olivier.Couet/ Fax: +41 22
> > > 7670300
> > >
> > > -----Original Message-----
> > > From: owner-roottalk_at_pcroot.cern.ch
> > > [mailto:owner-roottalk_at_pcroot.cern.ch] On Behalf Of
> > > alexis.cothenet_at_free.fr
> > > Sent: Monday, May 02, 2005 9:45 AM
> > > To: RootTalk
> > > Subject: [ROOT] pb Save canvas in jpg or gif format with v4.04
> > >
> > >
> > > Hi All,
> > >
> > >
> > > I just to try 4.04 binary version for cygwin.
> > > The macro below doesn't work anymore for saving canvas in .gif or .jpg.
> > > (with
> > > 4.03 it was working for .gif only and in 4.02 for both :-) ) I have the
> > > message:
> > > Error in <RootX11ErrorHandler>: BadMatch (invalid parameter attributes)
> > > (XID:
> > > 14680355, XREQ: 73)
> > >
> > > Is it a problem known ?
> > >
> > > {
> > > TCanvas * newcanvas = new
> > > TCanvas("newcanvas","newcanvas",710,10,700,500);
> > > cout<<"for gif"<<endl;
> > > newcanvas->SaveAs("spectrum.gif");
> > > cout<<"for jpg"<<endl;
> > > newcanvas->SaveAs("spectrum.jpg");
> > > }
> > >
> > > Thank you very much for your help.
> > >
> > > Regards,
> > > Alexis
> > >
> > >
> > >
>
>
Received on Mon May 02 2005 - 14:57:20 MEST

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:07 MET