以前使用R作图的时候,一直很忧虑怎么将两个图片拼接在一起,有一些是可以做到的,但是可能是自己了解的比较少,这样成功的例子比较少,但是现在发现一个很好的工具就是convert,这个的存在完美的解决了这个问题
首先先看一下convert的参数
Image Settings:
-adjoin 将图像连接到单个多图像文件中
-affine matrix 仿射变换矩阵
-alpha option activate, deactivate, reset, or set the alpha channel
-antialias remove pixel-aliasing
-authenticate password
decipher image with this password
-attenuate value lessen (or intensify) when adding noise to an image
-background color background color
-bias value add bias when convolving an image
-black-point-compensation
use black point compensation
-blue-primary point chromaticity blue primary point
-bordercolor color border color
-caption string assign a caption to an image
-channel type apply option to select image channels
-colors value preferred number of colors in the image
-colorspace type alternate image colorspace
-comment string annotate image with comment
-compose operator set image composite operator
-compress type type of pixel compression when writing the image
-define format:option
define one or more image format options
-delay value display the next image after pausing
-density geometry horizontal and vertical density of the image
-depth value image depth
-display server get image or font from this X server
-dispose method layer disposal method
-dither method apply error diffusion to image
-encoding type text encoding type
-endian type endianness (MSB or LSB) of the image
-family name render text with this font family
-fill color color to use when filling a graphic primitive
-filter type use this filter when resizing an image
-font name render text with this font
-format “string” output formatted image characteristics
-fuzz distance colors within this distance are considered equal
-gravity type horizontal and vertical text placement
-green-primary point chromaticity green primary point
-intent type type of rendering intent when managing the image color
-interlace type type of image interlacing scheme
-interpolate method pixel color interpolation method
-interword-spacing value
set the space between two words
-kerning value set the space between two letters
-label string assign a label to an image
-limit type value pixel cache resource limit
-loop iterations add Netscape loop extension to your GIF animation
-mask filename associate a mask with the image
-mattecolor color frame color
-monitor monitor progress
-orient type image orientation
-page geometry size and location of an image canvas (setting)
-ping efficiently determine image attributes
-pointsize value font point size
-preview type image preview type
-quality value JPEG/MIFF/PNG compression level
-quiet suppress all warning messages
-red-primary point chromaticity red primary point
-regard-warnings pay attention to warning messages
-remap filename transform image colors to match this set of colors
-respect-parentheses settings remain in effect until parenthesis boundary
-sampling-factor geometry
horizontal and vertical sampling factor
-scene value image scene number
-seed value seed a new sequence of pseudo-random numbers
-size geometry width and height of image
-stretch type render text with this font stretch
-stroke color graphic primitive stroke color
-strokewidth value graphic primitive stroke width
-style type render text with this font style
-taint image as ineligible for bi-modal delegate
-texture filename name of texture to tile onto the image background
-tile-offset geometry
tile offset
-treedepth value color tree depth
-transparent-color color
transparent color
-undercolor color annotation bounding box color
-units type the units of image resolution
-verbose print detailed information about the image
-view FlashPix viewing transforms
-virtual-pixel method
virtual pixel access method
-weight type render text with this font weight
-white-point point chromaticity white point

Image Operators:
-adaptive-blur geometry
adaptively blur pixels; decrease effect near edges
-adaptive-resize geometry
adaptively resize image using ‘mesh’ interpolation
-adaptive-sharpen geometry
adaptively sharpen pixels; increase effect near edges
-alpha option on, activate, off, deactivate, set, opaque, copy
transparent, extract, background, or shape
-annotate geometry text
annotate the image with text
-auto-orient automatically orient image
-bench iterations measure performance
-black-threshold value
force all pixels below the threshold into black
-blue-shift factor simulate a scene at nighttime in the moonlight
-blur geometry reduce image noise and reduce detail levels
-border geometry surround image with a border of color
-bordercolor color border color
-cdl filename color correct with a color decision list
-charcoal radius simulate a charcoal drawing
-chop geometry remove pixels from the image interior
-clip clip along the first path from the 8BIM profile
-clip-mask filename associate a clip mask with the image
-clip-path id clip along a named path from the 8BIM profile
-colorize value colorize the image with the fill color
-contrast enhance or reduce the image contrast
-contrast-stretch geometry
improve contrast by stretching' the intensity range -convolve coefficients apply a convolution kernel to the image -cycle amount cycle the image colormap -decipher filename convert cipher pixels to plain pixels -deskew threshold straighten an image -despeckle reduce the speckles within an image -distort method args distort images according to given method ad args -draw string annotate the image with a graphic primitive -edge radius apply a filter to detect edges in the image -encipher filename convert plain pixels to cipher pixels -emboss radius emboss an image -enhance apply a digital filter to enhance a noisy image -equalize perform histogram equalization to an image -evaluate operator value evaluate an expression over image values -extent geometry set the image size -extract geometry extract area from image -fft implements the discrete Fourier transform (DFT) -flip flip image vertically -floodfill geometry color floodfill the image with color -flop flop image horizontally -frame geometry surround image with an ornamental border -function name paramters apply function over image values -gamma value level of gamma correction -gaussian-blur geometry reduce image noise and reduce detail levels -geometry geometry perferred size or location of the image -identify identify the format and characteristics of the image -ift implements the inverse discrete Fourier transform (DFT) -implode amount implode image pixels about the center -lat geometry local adaptive thresholding -layers method optimize, merge, or compare image layers -level value adjust the level of image contrast -level-colors color,color level image using given colors -linear-stretch geometry improve contrast bystretching with saturation’
-liquid-rescale geometry
rescale image with seam-carving
-median radius apply a median filter to the image
-modulate value vary the brightness, saturation, and hue
-monochrome transform image to black and white
-motion-blur geometry
simulate motion blur
-negate replace every pixel with its complementary color
-noise radius add or reduce noise in an image
-normalize transform image to span the full range of colors
-opaque color change this color to the fill color
-ordered-dither NxN
add a noise pattern to the image with specific
amplitudes
-paint radius simulate an oil painting
-polaroid angle simulate a Polaroid picture
-posterize levels reduce the image to a limited number of color levels
-print string interpret string and print to console
-profile filename add, delete, or apply an image profile
-quantize colorspace reduce colors in this colorspace
-radial-blur angle radial blur the image
-raise value lighten/darken image edges to create a 3-D effect
-random-threshold low,high
random threshold the image
-recolor matrix translate, scale, shear, or rotate image colors
-region geometry apply options to a portion of the image
-render render vector graphics
-repage geometry size and location of an image canvas
-resample geometry change the resolution of an image
-resize geometry resize the image
-roll geometry roll an image vertically or horizontally
-rotate degrees apply Paeth rotation to the image
-sample geometry scale image with pixel sampling
-scale geometry scale the image
-segment values segment an image
-selective-blur geometry
selectively blur pixels within a contrast threshold
-sepia-tone threshold
simulate a sepia-toned photo
-set property value set an image property
-shade degrees shade the image using a distant light source
-shadow geometry simulate an image shadow
-sharpen geometry sharpen the image
-shave geometry shave pixels from the image edges
-shear geometry slide one edge of the image along the X or Y axis
-sigmoidal-contrast geometry
increase the contrast without saturating highlights or shadows
-sketch geometry simulate a pencil sketch
-solarize threshold negate all pixels above the threshold level
-sparse-color method args
fill in a image based on a few color points
-splice geometry splice the background color into the image
-spread radius displace image pixels by a random amount
-strip strip image of all profiles and comments
-swirl degrees swirl image pixels about the center
-threshold value threshold the image
-thumbnail geometry create a thumbnail of the image
-tile filename tile image when filling a graphic primitive
-tint value tint the image with the fill color
-transform affine transform image
-transparent color make this color transparent within the image
-transpose flip image vertically and rotate 90 degrees
-transverse flop image horizontally and rotate 270 degrees
-trim trim image edges
-type type image type
-unique-colors discard all but one of any pixel color
-unsharp geometry sharpen the image
-vignette geometry soften the edges of the image in vignette style
-wave geometry alter an image along a sine wave
-white-threshold value
force all pixels above the threshold into white

Image Sequence Operators:
-append append an image sequence
-average average an image sequence
-clut apply a color lookup table to the image
-coalesce merge a sequence of images
-combine combine a sequence of images
-composite composite image
-crop geometry cut out a rectangular region of the image
-deconstruct break down an image sequence into constituent parts
-flatten flatten a sequence of images
-fx expression apply mathematical expression to an image channel(s)
-hald-clut apply a Hald color lookup table to the image
-morph value morph an image sequence
-mosaic create a mosaic from an image sequence
-process arguments process the image with a custom image filter
-reverse reverse image sequence
-separate separate an image channel into a grayscale image
-write filename write images to this file

Image Stack Operators:
-clone index clone an image
-delete index delete the image from the image sequence
-insert index insert last image into the image sequence
-swap indexes swap two images in the image sequence

Miscellaneous Options:
-debug events display copious debugging information
-help print program options
-list type print a list of supported option arguments
-log format format of debugging information
-version print version information

1、如何得到一个图片的尺寸大小,输入这样的命令

identify 1.png

1.png PNG 2000x1200 2000x1200+0+0 16-bit DirectClass 21.7kb
2、拼图
横向拼接

convert 1.png 2.png +append result1.png

这样图片就变成了一行两列的图了
纵向拼接

convert 1.png 2.png -append result2.png

这样图片就变成了两行一列的图了
3、放大缩小

convert -resize 100x100 1.png n.png

100x100是图片的尺寸,也可以用百分比,50%x50%
4、图片翻转
上下翻转:

convert -flip 1.png 2.png

左右翻转:

convert -flop 1.png 2.png

1.png 是原始的图片,而2.png是翻转之后的图片
5、单色
把图片变为黑白颜色:

convert -monochrome 1.png 2.png

6、加噪声

convert -noise 3 1.png 2.png

7、油画效果
我们可以用这个功能,把一张普通的图片,变成一张油画,效果非常的逼真

convert -paint 4 1.png 2.png

8、旋转
把一张图片,旋转一定的角度:

convert -rotate 30 1.png 2.png

上面的30,表示向右旋转30度,如果要向左旋转,度数就是负数
9、炭笔效果

convert -charcoal 2 1.png 2.png

形成炭笔或者说是铅笔画的效果。
10、散射
1)毛玻璃效果:

convert -spread 30 1.png 2.png

2)漩涡
以图片的中心作为参照,把图片扭转,形成漩涡的效果:

convert -swirl 67 1.png 2.png

3)凸起效果
用-raise来创建凸边:

convert -raise 5x5 1.png 2.png

convert-----Linux中的图片处理工具相关推荐

  1. PS2: 这篇文章中的图片绘图工具使用的是Dia (sudo apt-get install dia)。据说yEd也很不错。...

    SBCL编译过程 - O.Nixie的专栏 - 博客频道 - CSDN.NET PS2: 这篇文章中的图片绘图工具使用的是Dia (sudo apt-get install dia).据说yEd也很不 ...

  2. Linux 中的 netcat 网络工具简介

    Linux 中的 netcat 网络工具简介 Apr 3, 2020 |  Linux |  linux netcat netcat 是 Linux 系统中的网络工具,其通过 TCP 和 UDP 协议 ...

  3. Kali Linux中优秀Wifi渗透工具TOP 10

    这篇文章要讨论的是目前一个非常热门的话题:渗透无线网络以及如何防止无线网络被入侵.WiFi 通常都是网络环境中的一个薄弱环节,因为 WiFi 信号可以在范围内的任何一个地方被任何一个人捕捉到,而且只要 ...

  4. kail linux中的渗透测试工具

    1.Nmap Nmap Nmap(即 "网络映射器")是 Kali Linux 上最受欢迎的信息收集工具之一.换句话说,它可以获取有关主机的信息:其 IP 地址.操作系统检测以及网 ...

  5. Linux中压缩解压工具使用

    1.压缩原理 目前我们使用的计算机系统是使用bytes单位计量的,实际上,计算机中最小的计量单位是bits 1 byte = 8 bits 在这里插入图片描述 一个空格代表一个bit,1byte就是8 ...

  6. linux上p图工具,Linux下的图片转换工具ImageMagick

    最近需要用到一些Linux下图片格式转换的内容,网上找到了这款ImageMagick的软件,提供的功能很多,支持png,jpg,gif,pdf等许多种图片格式的互相转换,而且开源,使用起来非常方便. ...

  7. Linux 中文件管理常用的工具

    文件管理常用的工具:cp .mv 及rm 复制命令: cp(copy) 使用格式: cp [OPTION]... [-T] SOURCE DESTcp [OPTION]... SOURCE... DI ...

  8. kali linux 截图位置,Kali Linux中使用shutter截图工具 | CN-SEC 中文网

    摘要 在Kali 2017以前的版本中默认有一款截图工具--screenshot,升级到2017版后找不到了,下面介绍一款同样好用的截图工具---shutter 在Kali 2017以前的版本中默认有 ...

  9. linux中nodejs后台运行工具forever

    forever让nodejs应用后台执行 命令如下: forever start './bin/www' nodejs一般是当成一条用户命令执行的,当用户断开客户连接,运用也就停了,很烦人.如何让no ...

最新文章

  1. java停车管理系统中期检查_java毕业设计_springboot框架的停车场收费管理系统
  2. swift 和 oc中检测textfield是否输入数字
  3. linux5启动过程及故障排除
  4. 列出AD用户Lockout 位置
  5. 基于i.MX RT1060的可编程视觉模块
  6. [更新中]Lucene.net,中文分词技术 ICTCLAS研究
  7. 批处理显示语句学习(echo、 @ 、 pause)
  8. Arduino+Max30100心率血氧浓度传感器测试
  9. 成功解决利用matplotlib.pyplot进行绘图的时候整个画布中的绘制曲线只显示一部分
  10. linux7主机名设置,centos7主机名、网络设置
  11. quartz定时器依赖_Grails集成Quartz插件实现定时任务(Job)
  12. JS收集:限制输入搜索串
  13. python学生名片系统_Python入门教程完整版400集(懂中文就能学会)快来带走
  14. android图片异步加载解决步骤
  15. 转移符 个人工作中使用记录一下
  16. Asp.net MVC 4 Html帮助类 II
  17. mysql 查找员工入职时间
  18. AES加密解密C语言实现
  19. 【Jsoup】 基本使用
  20. 怎么用软件测试睡眠质量差怎么办,睡眠监测 App 到底有没有用?我睡了 34 晚,做了一个实验...

热门文章

  1. 聊聊 Kafka: Kafka 的基础架构
  2. 请把我不会,换成我可以学
  3. 《大型网站技术架构》《K8S进阶实战》等书籍!送45本!读完工资多个0!
  4. 当你 ping 的时候,你知道背后发生了什么吗?
  5. 使用面部标记提取和深度神经网络进行“昏昏欲睡”的检测
  6. 程序员吐槽:去再好的互联网公司也就是个打工仔,还累出一身病
  7. 路径规划(Path Planning)与运动规划(Motion Planning)
  8. SQL与NoSQL区别-规范化
  9. 操作系统安全加固原理
  10. 5、找出100到1000内的不含9的素数,存到result.txt文件中