当前位置:网站首页>ImageMagick - add watermark
ImageMagick - add watermark
2020-11-06 22:22:00 【wffger】
background
Recently, I want to add my own watermark to my mind map , Many examples on the Internet use ImageMagick To complete . But a lot of code doesn't work locally . After some experiments , Find two ways .
Method 1
Code
stackoverflow Method improvement :
convert 'ISO_IEC 25010.jpg' \
\( \
-size 60x60 xc:none \
-fill grey \
-gravity center \
-draw "text 0,0 'wffger'" -rotate -30 -write mpr:wm \
+delete \
+clone -fill mpr:wm -draw 'color 0,0 reset' \
\) \
-compose Multiply \
-composite \
'ISO_IEC 25010-mark1.jpg'
explain
- -size, Control size , Set watermark spacing indirectly .
- xc:none, Set the watermark to have no background color ,xc by "X Constant Image".
- -fill, Set watermark font color , Can't set to white , Or be -compose Multiply Set to transparent
Method 2
Code
ImageMagick Official watermark guide :
convert -size 600x600 xc:none -fill grey \
-gravity NorthWest -draw "text 10,10 'wffger'" \
-gravity SouthEast -draw "text 5,15 'wffger'" \
miff:- |\
composite -tile - 'ISO_IEC 25010.jpg' 'ISO_IEC 25010-mark2.jpg'
explain
- -size, Set watermark image size .
- -tile, Tile the watermark .
Environmental Science
ydx@ydx-mf:~/ file $ uname -a
Linux ydx-mf 5.7.11-200.fc32.x86_64 #1 SMP Wed Jul 29 17:15:52 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
ydx@ydx-mf:~/ file $ rpm -qi ImageMagick
Name : ImageMagick
Epoch : 1
Version : 6.9.11.22
Release : 1.fc32
Architecture: x86_64
版权声明
本文为[wffger]所创,转载请带上原文链接,感谢
边栏推荐
- QT audio and video development 46 video transmission UDP version
- How much disk space does a file of 1 byte actually occupy
- VARCHART XGantt入门教程
- 2020-08-24:什么是小文件?很多小文件会有什么问题?很多小文件怎么解决?(大数据)
- Google browser realizes video playback acceleration function
- RFID fixed assets management system for fire equipment
- JS string - string string object method
- Detect certificate expiration script
- All the way, I was forced to talk about C code debugging skills and remote debugging
- A concise tutorial for Nacos, ribbon and feign
猜你喜欢
2020-09-04:函数调用约定了解么?
Design of NAND flash interface control
Method of code refactoring -- Analysis of method refactoring
移动端像素适配方案
List to map (split the list according to the key, and the value of the same key is a list)
Cloudquery v1.2.0 release
大佬们如何在nginx镜像里面增加模块?
2020-08-20: the difference between go and python?
To solve the problem that the data interface is not updated after WPF binding set
Composition of MRAM cache
随机推荐
Big data processing black Technology: revealing the parallel computing technology of Pb level data warehouse gaussdb (DWS)
Exclusive interview with Alibaba cloud database for 2020 PostgreSQL Asia Conference: Zeng Wenjing
August 30, 2020: naked write algorithm: the nearest common ancestor of two nodes in a binary tree.
迅为iMX6开发板-设备树内核-menuconfig的使用
The method of local search port number occupation in Windows system
The Interpreter pattern of behavior pattern
#JVM 类加载机制
Win7 AppCrash (solution)
Detailed software engineering -- the necessary graphs in each stage
To solve the problem that the data interface is not updated after WPF binding set
Google browser realizes video playback acceleration function
The essence of transaction and the principle of deadlock
实验一
Introduction to the development of small game cloud
Summary of common SQL statements
插件Bilibili新版0.5.5
QT audio and video development 46 video transmission UDP version
如何才能快速正确的部署甘特图
[learning] interface test case writing and testing concerns
Practice of Xiaoxiong school development board: real equipment access of smart street lamp sandbox experiment