Mailing list - Entries of 2005


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AW: [qftestJUI] extracting png image from .qrl protocol file


  • Subject: Re: AW: [qftestJUI] extracting png image from .qrl protocol file
  • From: Gregor Schmid <Gregor.Schmid@?.de>
  • Date: Thu, 13 Jan 2005 19:02:01 -0000

Hello Jérôme,

"Lang, Jérôme (FF)" <Jerome.Lang@?.com> writes:

> Hi Greg,
>
> well I forgot to mention that I only want a screenshot of my SUT if
> I got an exception or an error in my testsuite/SUT. And of course
> this screenshot, should be exactly at the moment of the occured
> exception/error. Like in the run-log. That's why I can't solve my
> problem with a jython script, I think.....

Hmm, in that case you'll have to do it the hard way. It's far from
trivial though. Definitely too much to quickly hack together and put
on the list here.

As I mentioned, you need a Base64 decoder to get the deflated byte
array for the image. Inflating with an InflaterInputStream will give
you the actual image data. Combined with the width and height you can
use a MemoryImageSource to create the Image which you can then save
using the PNGEncoder mention in the links from the previous posting.

Is there a general need for such a feature? Anybody else need this?

Best regards,
    Greg

--
Gregor Schmid                           Gregor.Schmid@?.de
Quality First Software GmbH                http://www.qfs.de
Tulpenstr. 41                           Tel: +49 8171 919870
DE-82538 Geretsried                     Fax: +49 8171 919876



Videos Downloads Documentation Buy Free Trial