The ImageObserver is used in the getWidth, getHeight and drawImage methods 
with the image that is passed in.
So in a sense it depends on the img that you are passing in. The observer is an 
object waiting for the image to be loaded.

How are you creating the image, can you get an abserver from there somehow.
Maybe you could use a dummy observer if the image is already loaded.


> How can I obtain an "java.awt.ImageObserver" that 
> I can pass to one of the "drawImage" methods of
> PDFDocumentGraphics2D?
> Example:
>          pdfgen = new PDFDocumentGraphics2D(true,System.out,800,1100);
>          ...
>          pdfgen.drawImage(img,100,100,50,50,imgObserver);
> With a pure AWT application, I would pass the java.awt.Panel whose "paint" 
> method invokes "drawImage".
> But with PDFDocumentGraphics2D, I don't have such a Panel object.
> Even if I create a surrogate one, the resulting PDF will not have the images in it.
> What can act as the "ImageObserver"?
> Thanks,
> Julio Lerm
> Chicago, IL

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to