@ Override public BufferedImage createCompatibleImage ( int width , int height ) { ColorModel model = getColorModel ( ) ; WritableRaster raster = model . createCompatibleWritableRaster ( width , height ) ; return new BufferedImage ( model , raster , model . isAlphaPremultiplied ( ) , null ) ; }
Creates a compatible image . This override is only here to provide support for Java 6 because from Java 7 onwards the super class has a non - abstract implementation for this method .