-
java 为图片添加水印 示例
为图片添加水印 【核心代码】 /*** 添加水印* @param imagePath 图片绝对路径* @param watermarkPath 水印图片绝对路径* @param position 水印图片位置* @return 生成水印图片的绝对路径*/public static String addWatermark(String imagePath, String watermarkPath, String position) {logger.info("为图片({})在位置{}添加水印({})", imagePath, position, watermarkPath);if (StringUtils.isNotBlank(imagePath) && StringUtils.isNotBlank(watermarkPath)) {File image = new File(imagePath);File watermark = new File(watermarkPath);Position pos = getPostion(position);if (image.isFile() && image.exists() && watermark.isFile()) {try {BufferedImage bi = ImageIO.read(image);Builder builder = Thumbnails.of(imagePath);BufferedImage watermarkImg = ImageIO.read(watermark);File newWatermark = null;// 原图的宽或高是水印图片宽或高的2倍及以上,则直接打上水印原图;否则缩略水印图片,以原图宽或高的二分之一if (bi.getWidth() / watermarkImg.getWidth()
- 2017-10-13下载
- 积分:1
-
一些比较全面的J2EE学习实例,希望对初学学者有所帮助
一些比较全面的J2EE学习实例,希望对初学学者有所帮助-some of the more comprehensive study J2EE example, and I hope to help beginners scholars!
- 2023-06-11 14:05:09下载
- 积分:1
-
J2ME 无线通信技术应用开发源代码
J2ME 无线通信技术应用开发源代码-J2ME wireless communication technology application development source code
- 2022-02-20 07:08:05下载
- 积分:1
-
gamemobile
tetris j2me game chua hoan chinh can chinh sua nhiu thu
- 2012-05-18 00:56:18下载
- 积分:1
-
J2ME的一个手机照相捕图例子
J2ME的一个手机照相捕图例子-J2ME mobile phone camera caught an example diagram
- 2022-12-20 19:50:08下载
- 积分:1
-
sendPhoto
用JavaME开发,在手机上传图片到服务器,高保真的生成一个png图片(With Java ME development, at cell phone picture upload to the server, high-fidelity to generate a png picture)
- 2009-03-21 23:22:59下载
- 积分:1
-
J2ME programming classic book, the author MARTIN J. WELLS, detailed descriptions...
J2ME编程的经典书籍,作者MARTIN J. WELLS,详尽介绍了J2ME编程基础-J2ME programming classic book, the author MARTIN J. WELLS, detailed descriptions of the programming based on the J2ME
- 2022-06-12 18:45:00下载
- 积分:1
-
用JAVA写的, 很不错的 对于初学者很有帮助,可以用作学习和研究之用,其中的有些处理值得借鉴...
用JAVA写的, 很不错的 对于初学者很有帮助,可以用作学习和研究之用,其中的有些处理值得借鉴-written with Java, and very good for beginners helpful, can be used for learning and research purposes, which should draw on some handling
- 2022-02-12 02:07:18下载
- 积分:1
-
一个经典的俄罗斯方块游戏看看吧,相信你会有收获的
一个经典的俄罗斯方块游戏看看吧,相信你会有收获的-A classic Tetris game to see it, I believe you will harvest
- 2022-07-09 01:01:05下载
- 积分:1
-
MIDlet允许动态生成SVG图像
Midlet that allow dynamic creation of an svg image-Midlet that allow dynamic creation of an svg image
- 2022-03-30 09:23:32下载
- 积分:1