Here you can find the source of cropImage(BufferedImage src, int x, int y, int w, int h)
public static BufferedImage cropImage(BufferedImage src, int x, int y, int w, int h)
//package com.java2s; //License from project: Open Source License import java.awt.image.BufferedImage; public class Main { public static BufferedImage cropImage(BufferedImage src, int x, int y, int w, int h) { BufferedImage dest = src.getSubimage(x, y, w, h); return dest; }/*from w ww . j a v a2 s.c om*/ }