ImageMagicK convert crop参数说明
作者:oxl 来源:Javadream 发布时间:2008-10-21 12:46:00
标签:ImageMagicK,参数,图片
-crop参数是从一个图片截取一个指定区域的子图片.
格式如下:
convert -crop widthxheight{+-}x{+-}y{%}
width 子图片宽度
height 子图片高度
x 为正数时为从区域左上角的x坐标,为负数时,左上角坐标为0,然后从截出的子图片右边减去x象素宽度.
y 为正数时为从区域左上角的y坐标,为负数时,左上角坐标为0,然后从截出的子图片上边减去y象素高度.
如:
convert -crop 300x400+10+10 src.jpg dest.jpg
从src.jpg坐标为x:10 y:10截取300x400的图片存为dest.jpg
convert -crop 300x400-10+10 src.jpg dest.jpg
从src.jpg坐标为x:0 y:10截取290x400的图片存为dest.jpg
0
投稿
猜你喜欢
- bool assert ( mixed $assertion [, string $description ] ) — 检查一个断言是否为
- 你们要的3D太阳系图片上传之后不知为何帧率降低了许多。。。日地月三体所谓三体,就是三个物体在重力作用下的运动。由于三点共面,所以三个质点仅在
- 一、python图形界面tk之滚动文本框的实现示例使用python的tkinter库实现滚动文本框的方式,目前我知道的有两种,一
- 代码如下:Function splitx(strs1 As String, strs2 A
- vue切换“页面”(路由)时保持滚动条回到顶部vue项目做pc端的时候,发现在两个页面切换时 滚动条
- Python写入Excel有时需要合并单元格、或者改变文字内容的颜色首先导入xlwt模块import xlwt创建文件名创建Excel工作簿
- 本文实例为大家分享了wxPython整点报时的具体代码,供大家参考,具体内容如下# C盘要有个wav文件,内含报时音频import wx &
- 用鼠标双击需要更改的变量,就会将其选中,选中的标志是相应变量名有了色块然后右键点击这个变量,找到Refactor,然后再选择Reanme然后
- 前言在ES6新增的数组方法中,包含了多个遍历方法,其中包含了用于筛选的filter和reducefilter主要用于筛选数组的filter方
- 关键字:js验证表单大全,用JS控制表单提交 ,javascript提交表单:目录:1:js 字符串长度限制、判断字符长度 、js限制输入、
- 以前工作的时候由于Oracle8i数据库经常出现用户过多的错误,由于数据量大,经常出现ORA:12500错误,但主要原因是访问过多而引起的,
- Oracle数据库查看一个进程是如何执行相关的实际SQL语句SELECT b.sql_text, sid, serial#, osuser,
- 最近使用工作需要,使用了Navicat8.2版本,发现备份数据都是默认存储在C盘,这个就比较郁闷了。重做系统忘记转移了。那不就死定了?找了一
- 实际效果:假设给定目录"/media/data/programmer/project/python" ,备份路径&quo
- 今天使用bootstrap和metroui设计了一个metro风格的移动app或者微信微网站的界面程序的源代码可以从此处获得:https:/
- 代码如下:# -*- coding: utf-8 -*-#!/usr/bin/python# filename: todo.py# code
- 都知道django每次请求都会连接数据库和释放数据库连接。Django为每个请求使用新的数据库连接。一开始这个方法行得通。然而随着服务器上的
- 我们对 DataFrame 进行选择,大抵从这三个层次考虑:行列、区域、单元格。其对应使用的方法如下:一. 行,列 --> df[]二
- sys模块在使用python开发脚本的时候,作为一个运维工具,或者是其他工具需要在接受用户参数运行时,这里就可以用到命令行传参的方式,可以给
- <html> <head> <title> New Document </title> &l