/** Jumps rightward num pixels from the current position. */ public void jumpPixels(int num) { src.jumpPixels(num); dst.jumpPixels(num); }
@SuppressWarnings("PMD.SystemPrintln") public static void printImage(RenderedImage renderedImage) { RectIter rectIter = RectIterFactory.create(renderedImage, null); do { do { double value = rectIter.getSampleDouble(); System.out.print(value + " "); } while (!rectIter.nextPixelDone()); rectIter.startPixels(); } while (!rectIter.nextLineDone()); } }
/** Sets the iterator to the leftmost pixel of its bounding rectangle. */ public void startPixels() { src.startPixels(); dst.startPixels(); }
/** Sets the iterator to the first line of its bounding rectangle. */ public void startLines() { src.startLines(); dst.startLines(); }
/** * Sets the iterator to the next line in the image, and returns {@code true} if the bottom row * of the bounding rectangle has been passed. */ public boolean nextLineDone() { boolean check = src.nextLineDone(); if (check == dst.nextLineDone()) { return check; } throw new RasterFormatException(ERROR); }
/** Sets the iterator to the next pixel in the image (that is, move rightward). */ public boolean nextPixelDone() { boolean check = src.nextPixelDone(); if (check == dst.nextPixelDone()) { return check; } throw new RasterFormatException(ERROR); }
/** Returns {@code true} if the right edge of the bounding rectangle has been passed. */ public boolean finishedPixels() { boolean check = src.finishedPixels(); if (check == dst.finishedPixels()) { return check; } throw new RasterFormatException(ERROR); }
/** Returns {@code true} if the bottom row of the bounding rectangle has been passed. */ public boolean finishedLines() { boolean check = src.finishedLines(); if (check == dst.finishedLines()) { return check; } throw new RasterFormatException(ERROR); }
/** Sets the specified sample of the current pixel to a double value. */ public void setSample(int b, double s) { dst.setSample(b, s); } }
/** Returns the specified sample of the current pixel as a double. */ public double getSampleDouble(int b) { return src.getSampleDouble(b); }
/** * Sets the iterator to the next band in the image, and returns {@code true} if the max band has * been exceeded. */ public boolean nextBandDone() { boolean check = src.nextBandDone(); if (check == dst.nextBandDone()) { return check; } throw new RasterFormatException(ERROR); }
/** Sets the iterator to the first band of the image. */ public void startBands() { src.startBands(); dst.startBands(); }
/** Returns {@code true} if the max band in the image has been exceeded. */ public boolean finishedBands() { boolean check = src.finishedBands(); if (check == dst.finishedBands()) { return check; } throw new RasterFormatException(ERROR); }
/** Sets the current sample to a double value. */ public void setSample(double s) { dst.setSample(s); }
/** Sets the specified sample of the current pixel to an integral value. */ public void setSample(int b, int s) { dst.setSample(b, s); }
/** Sets the specified sample of the current pixel to a float value. */ public void setSample(int b, float s) { dst.setSample(b, s); }