Prepares an image for rendering.
If the values of the width and height arguments are both -1
, this method prepares the image for rendering on the default screen; otherwise, this method prepares an image for rendering on the default screen at the specified width and height.
The image data is downloaded asynchronously in another thread, and an appropriately scaled screen representation of the image is generated.
This method is called by components prepareImage
methods.
Information on the flags returned by this method can be found with the definition of the ImageObserver
interface.
@param image the image for which to prepare ascreen representation.
@param width the width of the desired screenrepresentation, or -1
.
@param height the height of the desired screenrepresentation, or -1
.
@param observer the ImageObserver
object to be notified as the image is being prepared.
@return true
if the image has already beenfully prepared; false
otherwise.
@see java.awt.Component#prepareImage(java.awt.Image,java.awt.image.ImageObserver)
@see java.awt.Component#prepareImage(java.awt.Image,int,int,java.awt.image.ImageObserver)
@see java.awt.image.ImageObserver