This interface is designed to be an optional additional API supported by some implementations of
Image
to allow them to provide alternate images for various rendering resolutions. The various
Graphics.drawImage(...)
variant methods will consult the methods of this interface if it is implemented on the argument
Image
object in order to choose the best representation to use for each rendering operation.
The MultiResolutionImage
interface should be implemented by any subclass of java.awt.Image
whose instances are intended to provide image resolution variants according to the given image width and height. For convenience, toolkit images obtained from Toolkit.getImage(String name)
and Toolkit.getImage(URL url)
will implement this interface on platforms that support naming conventions for resolution variants of stored image media and the AbstractMultiResolutionImage
and BaseMultiResolutionImage
classes are provided to facilitate easy construction of custom multi-resolution images from a list of related images.