tldr/pages/common/mogrify.md

25 lines
661 B
Markdown
Raw Normal View History

2017-08-20 18:37:03 +01:00
# mogrify
> Perform operations on multiple images, such as resizing, cropping, flipping, and adding effects.
2017-09-11 12:05:15 +01:00
> Changes are applied directly to the original file.
2017-08-20 18:37:03 +01:00
- Resize all JPEG images in the folder to 50% of their initial size:
2017-08-20 18:37:03 +01:00
`mogrify -resize {{50%}} {{*.jpg}}`
2017-09-11 12:05:15 +01:00
- Resize all images starting with "DSC" to 800x600:
2017-08-20 18:37:03 +01:00
`mogrify -resize {{800x600}} {{DSC*}}`
- Convert all PNG images in the folder to JPEG:
2017-08-20 18:37:03 +01:00
`mogrify -format {{jpg}} {{*.png}}`
- Halve the saturation of all image files in the current directory:
2017-08-20 18:37:03 +01:00
`mogrify -modulate {{100,50}} {{*}}`
- Double the brightness of all image files in the current directory:
2017-08-20 18:37:03 +01:00
`mogrify -modulate {{200}} {{*}}`