ECONVERT(1)
π ECONVERT(1) β the ExactImage Manual, but make it a group chat π
okay bestie, sit down, hydrate, and let me tell you about econvert β it's the image converter of the ExactImage toolkit, and it lives in section 1 of the manual. yeah. we're doing man page section 1 today. iconic behavior honestly. β¨
π SYNOPSIS π
like, here's the whole vibe in one code block, no notes:
econvert [option...] [{-i | --input} input-file...]
[{-o | --output} output-file...]
econvert {-h | --help}
that's it. that's the shape of it. π¦
πΈ DESCRIPTION πΈ
so ExactImage is a fast C++ image processing library. and the way it eats? unlike a lot of other library frameworks, it lets you operate in several color spaces and bit depths natively, which means low memory and low computational requirements. slay. efficiency is the moment. π
econvert is the command line frontend for that library, and it mimics ImageMagick's convert. BUT β and this is the plot twist, bestie β econvert syntax is NOT compatible with convert. π they're cousins, not twins. do not just copy-paste your convert commands and expect a happy ending.
β¨ OPTIONS β¨
π«Ά Input/output
-ifile,--inputfile β read the image from the file you specify. oh and optionally? filenames can be prefixed with the format name, likejpg:-orraw:rgb8-dump. so fancy. π-ofile,--outputfile β save the output image to the file you specify. same deal: optionally prefix the filename with the format name, e.g.jpg:-orraw:rgb8-dump. π-afile,--appendfile β append the output image to the specified file. β οΈ the existing image must have the same width as the one being appended. also, optionally, filenames can be prefixed with the format name, e.g.jpg:-orraw:rgb8-dump.--compressmethod β use the specified compression method when writing images, e.g.G3,G4,Zip, ... the default depends on the output format. iykyk. π--decompressmethod β use the specified decompression method when reading images.--qualityn β the quality used for writing compressed images. valid values are integers from 0 to 100. the default is 75. no cap.--resolutionxdpi [ydpi] β set metadata resolution. π--sizewidth height β set image dimensions for raw images.--splitfile... β split the image in the Y-direction into multiple images. it's giving βοΈ.
π¦ Scaling, cropping, transformations
--bicubic-scalex β scale image data with a bi-cubic filter. use scale factor x.--bilinear-scalex β scale image data with a bi-linear filter. use scale factor x.--box-scalex β (down)scale image data with a box filter. use scale factor x.--ddt-scalex β scale image data with data dependent triangulation. use scale factor x.--nearest-scalex β scale image data to nearest neighbour. use scale factor x.--scalex β scale image data using a method suitable for the specified factor x. let it pick, bestie. it knows. π--thumbnailx β quick and dirty down-scale for a thumbnail. use scale factor x. literally the "we ball" of scaling.--cropx y w h β crop the specified area out of the image. π--fast-auto-cropβ fast auto crop.--flipβ flip the image vertically.--flopβ flip the image horizontally. (yes, flop. it's a real word here. we love her.)--rotaten β rotate the image n degrees. π
π Colors
--brightnessx β change the image brightness.--contrastx β change the image contrast.--saturationx β change the image saturation.--lightnessx β change the image lightness.--huex β change the image hue.--negateβ negate the image.--gammax β change the image gamma.--normalizeβ transform the image to span the full color range.--colorspacecolorspace β convert image colorspace. valid values are:BW,BILEVEL,GRAY,GRAY1,GRAY2,GRAY4,RGB,YUVandCYMK. (yes,CYMK. exactly like that. don't @ me, that's what the page says. π)--floyd-steinbergn β perform Floyd-Steinberg dithering using n shades.--riemersman β perform Riemersma dithering using n shades.
π§ Filters
--blurstdev β perform gaussian blur with standard deviation stdev.--deinterlaceβ shuffle every 2nd line. shuffle. like a playlist. π§--edgeβ detect edges.--convolvex11 x12 ... x1n ... xn1 xn2 ... xnn β convolve the image using the specified convolution matrix. yes, you literally type out the whole matrix. it's giving math homework but make it cute. β¨
π Drawing
--foregroundcolor β set foreground color.--backgroundcolor β set background color.--fontfont β use the specified font for drawing text.--text-rotationn β use the specified text rotation.--textx1 y1 height text β draw text.--stroke-widthn β set stroke width for vector primitives.--linex1 y1 x2 y2 β draw a line.
π Help
-h,--helpβ display help text and exit. our emotional support flag. π«Ά
β EXAMPLES β
Basics
image data must be read using -i or --input, processing routines get selected by their name with two leading dashes (e.g. --rotate), and at any point the data might be written into a file with -o or --output. for example:
econvert -i lenea.tiff --box-scale 0.5 -o medium.png --box-scale 0.5 -o little.png
see how it chains? pipeline queen behavior. π
Lossless transformations of JPEG files
the library delays image decoding as much as possible and provides lossless algorithms that work on compressed data (like JPEGs) directly. obsessed:
econvert -i AV220-Scan.JPG --resolution 300x300 -o 1.jpg --rotate 90 -o 2.jpg --rotate 180 -o 3.jpg --rotate -90 -o 4.jpg --flip -o 5.jpg --flop -o 6.jpg --scale 0.25 -o thumb.jpg
in this example 1.jpg will be created from the original JPEG DCT coefficients, those coefficients will be rearranged, and 2.jpg, 3.jpg, 4.jpg, 5.jpg and 6.jpg will be written without any additional loss in quality. π so clean. only at the very end, for the image thumb.jpg, does the DCT actually get decoded β but thanks to the accelerated JPEG scaling, only partially.
Thumbnails of bi-level images
when 1 bit, black and white images get scaled down, the output often looks bad, because the library algorithms always operate in the color-space the image data is stored in. π to work around this, the colorspace must be changed (e.g. to 8 bit gray) before applying the box scaler. at the end, the result might be converted back to just a few shades of gray, like 2 or 4 bit:
econvert -i avision-bw-scan.pbm --colorspace gray8 --box-scale 0.125 --colorspace gray2 -o thumb.png
order matters bestie. colorspace first. periodt.
Faster JPEG down-scaling
if you don't care about quality and only care about throughput, you can force nearest neighbor scaling by just specifying a scale factor the JPEG decoder can accelerate (Β½, ΒΌ, or 1/8) and then apply the remaining scaling manually. to get faster scaling with the effective factor 1/3:
econvert -i big.jpg --scale .5 --nearest-scale 0.66 -o thumb.jpg
math girlies rise. π₯
Working with digital camera RAW data
a wide range of digital camera RAW formats is supported. usually decoding of RAW data should be transparent and automatic, however some formats are also valid TIFF files, and the embedded thumbnail might get picked in favour of the actual RAW content. in these cases the dcraw decoder can explicitly be requested with the decoder prefix of the input parameter:
econvert -i dcraw:img_0123.cr2 ...
to quickly extract the embedded thumbnail preview, specify thumb as the decompression method before the image is loaded:
econvert --decompress thumb -i dcraw:img_0123.cr2 ...
Loading arbitrary raw data
it is possible to load arbitrary raw data via the raw: codec specification. color-depth (colorspace) and size for the raw data have to be explicitly specified:
econvert --size 1696x32 --colorspace rgb8 -i raw:data-file ...
no defaults, no guessing, you tell it exactly what's up. π
π SEE ALSO π
π AUTHORS π
- Jakub Wilk
<jwilk@debian.org>β wrote this manual page for the Debian system. π«Ά thank you king. https://exactcode.com/opensource/exactimage/β this manual page incorporates texts found on the ExactImage homepage.
π COPYRIGHT π
this manual page was written for the Debian system (and may be used by others).
permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 2 or (at your option) any later version published by the Free Software Foundation.
on Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common-licenses/GPL-2.
and that's the whole page, bestie!! π this one's econvert, from the ExactImage manual, dated 04/11/2010 β so yeah she's a vintage icon and she still ate. mwah. πβ¨π
π¦ where this page comes from
- debian bookworm: exactimage 1.0.2-11+b2 Β· GPL-2.0-only
- debian trixie: exactimage 1.2.1-2 Β· GPL-2.0-only
- ubuntu jammy: exactimage 1.0.2-8build3 Β· GPL-2.0-only
- ubuntu noble: exactimage 1.0.2-11build9 Β· GPL-2.0-only
- ubuntu questing: exactimage 1.2.1-2
- ubuntu resolute: exactimage 1.2.1-2build2 Β· GPL-2.0-only
- ubuntu stonking: exactimage 1.2.1-3build2 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms