Lines Matching defs:src

146      * @param src the source <code>BufferedImage</code> to filter
148 * filtered <code>src</code>
150 * @throws NullPointerException if <code>src</code> is <code>null</code>
151 * @throws IllegalArgumentException if <code>src</code> equals
153 * @throws ImagingOpException if <code>src</code> cannot be filtered
155 public final BufferedImage filter (BufferedImage src, BufferedImage dst) {
156 if (src == null) {
157 throw new NullPointerException("src image is null");
159 if (src == dst) {
160 throw new IllegalArgumentException("src image cannot be the "+
165 ColorModel srcCM = src.getColorModel();
172 src = icm.convertToIntDiscrete(src.getRaster(), false);
173 srcCM = src.getColorModel();
177 dst = createCompatibleDestImage(src, null);
187 dst = createCompatibleDestImage(src, null);
191 dst = createCompatibleDestImage(src, null);
196 if (ImagingLib.filter(this, src, dst) == null) {
197 throw new ImagingOpException ("Unable to convolve src image");
223 * @param src the source <code>Raster</code> to filter
225 * filtered <code>src</code>
227 * @throws NullPointerException if <code>src</code> is <code>null</code>
228 * @throws ImagingOpException if <code>src</code> and <code>dst</code>
230 * @throws ImagingOpException if <code>src</code> cannot be filtered
231 * @throws IllegalArgumentException if <code>src</code> equals
234 public final WritableRaster filter (Raster src, WritableRaster dst) {
236 dst = createCompatibleDestRaster(src);
238 else if (src == dst) {
239 throw new IllegalArgumentException("src image cannot be the "+
242 else if (src.getNumBands() != dst.getNumBands()) {
243 throw new ImagingOpException("Different number of bands in src "+
247 if (ImagingLib.filter(this, src, dst) == null) {
248 throw new ImagingOpException ("Unable to convolve src image");
257 * @param src Source image for the filter operation.
262 public BufferedImage createCompatibleDestImage(BufferedImage src,
266 int w = src.getWidth();
267 int h = src.getHeight();
272 destCM = src.getColorModel();
280 wr = src.getData().createCompatibleWritableRaster(w, h);
304 public WritableRaster createCompatibleDestRaster(Raster src) {
305 return src.createCompatibleWritableRaster();
313 public final Rectangle2D getBounds2D(BufferedImage src) {
314 return getBounds2D(src.getRaster());
322 public final Rectangle2D getBounds2D(Raster src) {
323 return src.getBounds();