These options appear throughout the quickstart, tutorial, and batch how-to. Dimension strings (Documentation Index
Fetch the complete documentation index at: https://hackmamba-3f164318.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
800x600>, 50%, …) are covered in the Geometry syntax reference.
-strip
Role: Operator. Removes profiles, comments, and other metadata blobs from the current image at the point it appears in the command line.
Syntax: -strip (no arguments).
Typical use: Web delivery and privacy (strip EXIF GPS, device names, ICC profiles you do not intend to ship).
Example:
-quality
Role: Setting. Sets lossy compression for the next JPEG, WebP, or similar write, until you change it again. Does not apply the same numeric scale to every format the same way; treat values as tunable defaults.
Syntax: -quality integer (commonly 1–100; higher is usually better fidelity and larger files for JPEG and WebP).
Typical use: Balance file size vs. artifacts after -resize and before the output filename.
Across these docs: examples often use -quality 85 for web-bound JPEG and WebP so copy-paste commands match each other; treat that as a starting point, not a requirement. Tune per asset and format.
Example:
-auto-orient
Role: Operator. Reads EXIF orientation, physically rotates pixels to upright, and normalizes orientation metadata so downstream -resize uses correct width/height.
Syntax: -auto-orient (no arguments).
Typical use: Phone photos before any geometry that assumes “width” is the long edge of the displayed picture.
Example:
-gravity
Role: Setting. Chooses an anchor for placement operators (-crop, -extent, -composite, -annotate, …) until you change or clear it.
Syntax: -gravity name
Common values: NorthWest (default), North, NorthEast, West, Center, East, SouthWest, South, SouthEast. For text overlays you may also see directional hints like North for “top-centered.”
Example (crop from center):
-gravity None when you need the default origin again.
-background
Role: Setting. Defines the color used when an operator creates new pixels (letterboxing, -extent, flattened alpha, etc.).
Syntax: -background color
Values: Named colors (white, black, none for transparent), #RRGGBB, #RRGGBBAA, or expressions like srgb(255,255,255) depending on build.
Example (pad to square with white bars):
-composite
Role: Operator. Merges the current image stack (typically a base image plus one overlay loaded just before this token). Often paired with -gravity and -geometry for margins.
Syntax: -composite (no arguments). With multiple pairs of overlays, ImageMagick composites in order; see the official composite docs for advanced forms.
Typical pattern: magick base.ext overlay.ext -gravity SouthEast -geometry +20+20 -composite out.ext
Example:
input.jpg is the bottom layer, watermark.png is stacked on top, and -composite flattens them using the given gravity and offset.