java.awt.image.PixelGrabber (JDK 1.0)
This class is an ImageConsumer that extracts a specified rectangular array of pixels (in the default RGB color model) from a specified Image or ImageProducer and stores them into a specified array (using the specified offset into the array and specified scanline size). Use this class when you want to inspect or manipulate the data of an image or some rectangular portion of an image.
The method grabPixels() makes the PixelGrabber start grabbing pixels. status() returns the status of the pixel-grabbing process. The return value uses the same flag value constants as the ImageObserver class does. The remaining methods are the standard ImageConsumer methods and should not be called directly.
public classPixelGrabberextends Object implements ImageConsumer { //Public ConstructorspublicPixelGrabber(Imageimg, intx, inty, intw, inth, int[]pix, intoff, intscansize); publicPixelGrabber(ImageProducerip, intx, inty, intw, inth, int[]pix, intoff, intscansize); 1.1 publicPixelGrabber(Imageimg, intx, inty, intw, inth, booleanforceRGB); //Public Instance Methods1.1 public synchronized voidabortGrabbing(); 1.1 public synchronized ColorModelgetColorModel(); 1.1 public synchronized intgetHeight(); 1.1 public synchronized ObjectgetPixels(); 1.1 public synchronized intgetStatus(); 1.1 public synchronized intgetWidth(); public booleangrabPixels() throws InterruptedException; public synchronized booleangrabPixels(longms) throws InterruptedException; public synchronized voidimageComplete(intstatus); //From ImageConsumerpublic voidsetColorModel(ColorModelmodel); //From ImageConsumerpublic voidsetDimensions(intwidth, intheight); //From ImageConsumerpublic voidsetHints(inthints); //From ImageConsumerpublic voidsetPixels(intsrcX, intsrcY, intsrcW, intsrcH, ColorModelmodel, public voidsetPixels'u'byte[]pixels, intsrcOff, intsrcScan); //From ImageConsumerpublic voidsetPixels(intsrcX, intsrcY, intsrcW, intsrcH, ColorModelmodel, public voidsetPixels'u'int[]pixels, intsrcOff, intsrcScan); //From ImageConsumerpublic voidsetProperties(Hashtableprops); //From ImageConsumer1.1 public synchronized voidstartGrabbing(); public synchronized intstatus(); }