来自http://examples.javapregeeks.com/desktop-java/awt/image/flipping-a-
buffered-image:
// Flip the image verticallyAffineTransform tx = AffineTransform.getScaleInstance(1, -1);tx.translate(0, -image.getHeight(null));AffineTransformOp op = new AffineTransformOp(tx, AffineTransformOp.TYPE_NEAREST_NEIGHBOR);image = op.filter(image, null);// Flip the image horizontallytx = AffineTransform.getScaleInstance(-1, 1);tx.translate(-image.getWidth(null), 0);op = new AffineTransformOp(tx, AffineTransformOp.TYPE_NEAREST_NEIGHBOR);image = op.filter(image, null);// Flip the image vertically and horizontally; equivalent to rotating the image 180 degreestx = AffineTransform.getScaleInstance(-1, -1);tx.translate(-image.getWidth(null), -image.getHeight(null));op = new AffineTransformOp(tx, AffineTransformOp.TYPE_NEAREST_NEIGHBOR);image = op.filter(image, null);



