> Date: Fri, 3 Sep 1999 07:27:05 -0700
> From: Ananth <[EMAIL PROTECTED]>
> Subject: Re: [JAVA2D] How to save the entire Frame as a gif or jpeg
> To: [EMAIL PROTECTED]
>
> Thank you very much for your response. I got a couple of more questions
regarding this.
> If someone could give me pointers on them, I would highly appreciate it.
>
> 1. java.awt.Robot's screenCapture method returns a java.awt.Image, whereas
> JPegEncoders's encode method takes in java.awt.image.BufferedImage!
> Is there any workaround for this?
Create a BufferedImage and get a Graphics2D (using createGraphics(). Then
drawImage the java.awt.Image from the screenCapture into this BufferedImage.
> 2. What I'm trying to accomplish is to create an image on Server side.
> But I'm trying to use Swing components to create a jazzy Panel and then
trying to save that as a gif/jpeg.
> So I would not really even want to display the Panel on the screen (means I
would not be using setVisible(true) on the panel!).
> Any pointers???
Again, draw the swing components into a BufferedImage (i.e. offscreen image).
jeannette
>
> --Ananth.
>
> ===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff JAVA2D-INTEREST". For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".