59 * Returns a unique instance of an ImageFilter object which will 60 * actually perform the filtering for the specified ImageConsumer. 61 * The default implementation just clones this object. 62 * <p> 63 * Note: This method is intended to be called by the ImageProducer 64 * of the Image whose pixels are being filtered. Developers using 65 * this class to filter pixels from an image should avoid calling 66 * this method directly since that operation could interfere 67 * with the filtering operation. 68 * @param ic the specified {@code ImageConsumer} 69 * @return an {@code ImageFilter} used to perform the 70 * filtering for the specified {@code ImageConsumer}. 71 */ 72 public ImageFilter getFilterInstance(ImageConsumer ic) { 73 ImageFilter instance = (ImageFilter) clone(); 74 instance.consumer = ic; 75 return instance; 76 } 77 78 /** 79 * Filters the information provided in the setDimensions method 80 * of the ImageConsumer interface. 81 * <p> 82 * Note: This method is intended to be called by the ImageProducer 83 * of the Image whose pixels are being filtered. Developers using 84 * this class to filter pixels from an image should avoid calling 85 * this method directly since that operation could interfere 86 * with the filtering operation. 87 * @see ImageConsumer#setDimensions 88 */ 89 public void setDimensions(int width, int height) { 90 consumer.setDimensions(width, height); 91 } 92 93 /** 94 * Passes the properties from the source object along after adding a 95 * property indicating the stream of filters it has been run through. 96 * <p> 97 * Note: This method is intended to be called by the ImageProducer 98 * of the Image whose pixels are being filtered. Developers using | 59 * Returns a unique instance of an ImageFilter object which will 60 * actually perform the filtering for the specified ImageConsumer. 61 * The default implementation just clones this object. 62 * <p> 63 * Note: This method is intended to be called by the ImageProducer 64 * of the Image whose pixels are being filtered. Developers using 65 * this class to filter pixels from an image should avoid calling 66 * this method directly since that operation could interfere 67 * with the filtering operation. 68 * @param ic the specified {@code ImageConsumer} 69 * @return an {@code ImageFilter} used to perform the 70 * filtering for the specified {@code ImageConsumer}. 71 */ 72 public ImageFilter getFilterInstance(ImageConsumer ic) { 73 ImageFilter instance = (ImageFilter) clone(); 74 instance.consumer = ic; 75 return instance; 76 } 77 78 /** 79 * Returns a unique instance of an ImageFilter object used to perform 80 * the filtering for an image which size is scaled (relative to 81 * the original image size). 82 * The default implementation just clones this object. 83 * <p> 84 * @param scaleX the specified scale factor fox x-axis 85 * @param scaleY the specified scale factor fox y-axis 86 * @return an {@code ImageFilter} used to perform the 87 * filtering for scaled images. 88 */ 89 public ImageFilter getScaledFilterInstance(double scaleX, double scaleY) { 90 return (ImageFilter) clone(); 91 } 92 93 /** 94 * Filters the information provided in the setDimensions method 95 * of the ImageConsumer interface. 96 * <p> 97 * Note: This method is intended to be called by the ImageProducer 98 * of the Image whose pixels are being filtered. Developers using 99 * this class to filter pixels from an image should avoid calling 100 * this method directly since that operation could interfere 101 * with the filtering operation. 102 * @see ImageConsumer#setDimensions 103 */ 104 public void setDimensions(int width, int height) { 105 consumer.setDimensions(width, height); 106 } 107 108 /** 109 * Passes the properties from the source object along after adding a 110 * property indicating the stream of filters it has been run through. 111 * <p> 112 * Note: This method is intended to be called by the ImageProducer 113 * of the Image whose pixels are being filtered. Developers using |