"Spectron International, Inc." wrote:
>
> I need to create an Image object in a servlet. The problem is that the
> createImage() functions seems to need AWT and I can't create an AWT object
> in a servlet because it always tries to connect to the X Server. Is there
> something like a MemoryImage class that I can create to use as an offscreen
> canvas in a servlet? I need that because I wan't to be able to return a GIF
> image from a servlet like:
>
> <IMG STR="/servlets/GifCreator">
It's a "feature" of the AWT. A good solution is to run the Xvfb X server
(part of the XFree86 suite; you'll find it in most distributions) - it
runs an X server in a virtual frame buffer instead of a physical
display. That will make AWT happy without requiring a real display.
Nathan
----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]