// To create a buffered image, see e666 创建缓冲图像

    // Flip the image vertically
AffineTransform tx = AffineTransform.getScaleInstance(1, -1);
tx.translate(0, -image.getHeight(null));
AffineTransformOp op = new AffineTransformOp(tx, AffineTransformOp.TYPE_NEAREST_NEIGHBOR);
bufferedImage = op.filter(bufferedImage, null); // Flip the image horizontally
tx = AffineTransform.getScaleInstance(-1, 1);
tx.translate(-image.getWidth(null), 0);
op = new AffineTransformOp(tx, AffineTransformOp.TYPE_NEAREST_NEIGHBOR);
bufferedImage = op.filter(bufferedImage, null); // Flip the image vertically and horizontally;
// equivalent to rotating the image 180 degrees
tx = AffineTransform.getScaleInstance(-1, -1);
tx.translate(-image.getWidth(null), -image.getHeight(null));
op = new AffineTransformOp(tx, AffineTransformOp.TYPE_NEAREST_NEIGHBOR);
bufferedImage = op.filter(bufferedImage, null);
Related Examples

最新文章

  1. BFS
  2. noip模拟赛 纸壳子
  3. Webkit CSS properties
  4. ubuntu的目录结构
  5. 4-Highcharts 3D图之3D普通饼图
  6. WSB备份到远程共享文件夹的限制
  7. Java中注解Annotation的定义、使用、解析
  8. Gulp实战和原理解析
  9. RTMP、RTSP、HTTP视频协议详解(转)
  10. python 读取SQLServer数据插入到MongoDB数据库中
  11. Linux Shell编程(6)——变量替换
  12. python之安装
  13. c++对文件操作的支持(二)
  14. C# 时间格式总结
  15. Vue组件库的那些事儿,你都知道吗?
  16. python编码问题和逻辑运算
  17. 修改eclipse的workspace目录
  18. ldap集成bitbucket
  19. requests库(爬虫)
  20. Java HashMap 遍历、删除、排序

热门文章

  1. django中cookies和session
  2. unity5 Edit Collider
  3. Android开发2——创建测试项目
  4. Spring Boot 2.0官方文档之 Actuator(转)
  5. JS随机生成不重复数据的代码分享
  6. 将一个4X4的数组进行逆时针旋转90度后输出,要求原数组数据随机输入
  7. python3和2的区别
  8. hdoj 2717 Catch That Cow
  9. jquery ajax中success与complete的执行顺序 (转)
  10. Echarts的option中的data问题