.\" Hey, EMACS: -*- nroff -*- .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) .TH OIIOTOOL 1 "Aug 10, 2013" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: .\" .nh disable hyphenation .\" .hy enable hyphenation .\" .ad l left justify .\" .ad b justify to both left and right margins .\" .nf disable filling .\" .fi enable filling .\" .br insert line break .\" .sp insert n+1 empty lines .\" for manpage-specific macros, see man(7) .SH NAME oiiotool \- the OIIO Swiss Army Knife .SH SYNOPSIS .B oiiotool .RI [ filename | option | action ]... .SH DESCRIPTION .\" TeX users may be more comfortable with the \fB\fP and .\" \fI\fP escape sequences to invode bold face and italics, .\" respectively. The \fBoiiotool\fP program will read images (from any file format for which an ImageInput plugin can be found), perform various operations on them, and write images (in any format for which an ImageOutput plugin can be found). .PP The oiiotool utility is invoked as follows: .B oiiotool .RI args oiiotool maintains an image stack, with the top image in the stack also called the current image. The stack begins containing no images. .PP oiiotool arguments consist of image names, or commands. When an image name is encountered, that image is pushed on the stack and becomes the new current image. .PP Most other commands either alter the current image (replacing it with the alteration), or in some cases will pull more than one image off the stack (such as the current image and the next item on the stack) and then push a new image. .PP For a complete description, see .IR /usr/share/doc/openimageio-doc/openimageio.pdf.gz . .SH OPTIONS .SS Options (general): .TP .B \-\-help Print help message .TP .B \-v Verbose status messages .TP .B \-q Quiet mode (turn verbose off) .TP .B \-\-runstats Print runtime statistics .TP .B \-a Do operations on all subimages/miplevels .TP .B \-\-info Print resolution and metadata on all inputs .TP .BI \-\-metamatch\ %s Regex: which metadata is printed with -info -v .TP .BI \-\-no\-metamatch\ %s Regex: which metadata is excluded with -info -v .TP .B \-\-stats Print pixel statistics on all inputs .TP .B \-\-hash Print SHA-1 hash of each input image .TP .BI \-\-colorcount\ %s Count of how many pixels have the given color (argument: color;color;...) (optional args: eps=color) .TP .BI \-\-rangecheck\ %s\ %s Count of how many pixels are outside the low and high color arguments (each is a comma-separated color value list) .TP .B \-\-no\-clobber Do not overwrite existing files .TP .BI \-\-threads\ %d Number of threads (default 0 == #cores) .TP .BI \-\-frames\ %s Frame range for '#' wildcards .TP .BI \-\-framepadding\ %d Frame number padding digits .SS Commands that write images: .TP .BI \-o\ %s Output the current image to the named file .SS Options that affect subsequent image output: .TP .BI \-d\ %s \&'-d TYPE' sets the output data format of all channels, '-d CHAN=TYPE' overrides a single named channel (multiple -d args are allowed). .br Data types include: uint8, sint8, uint10, uint12, uint16, sint16, half, float, double .TP .B \-\-scanline Output scanline images .TP .BI \-\-tile\ %d\ %d Output tiled images (tilewidth, tileheight) .TP .BI \-\-compression\ %s Set the compression method .TP .BI \-\-quality\ %d Set the compression quality, 1-100 .TP .BI \-\-planarconfig\ %s Force planarconfig (contig, separate, default) .TP .B \-\-adjust\-time Adjust file times to match DateTime metadata .TP .B \-\-noautocrop Do not automatically crop images whose formats don't support separate pixel data and full/display windows .TP .B \-\-autotrim Automatically trim black borders upon output to file formats that support separate pixel data and full/display windows .SS Options that change current image metadata (but not pixel values): .TP .BI \-\-attrib\ %s\ %s Sets metadata attribute (name, value) .TP .BI \-\-sattrib\ %s\ %s Sets string metadata attribute (name, value) .TP .BI \-\-caption\ %s Sets caption (ImageDescription metadata) .TP .BI \-\-keyword\ %s Add a keyword .TP .B \-\-clear\-keywords Clear all keywords .TP .BI \-\-orientation\ %d Set the assumed orientation .TP .B \-\-rotcw Rotate orientation 90 deg clockwise .TP .B \-\-rotccw Rotate orientation 90 deg counter-clockwise .TP .B \-\-rot180 Rotate orientation 180 deg .TP .BI \-\-origin\ %s Set the pixel data window origin (e.g. +20+10) .TP .BI \-\-fullsize\ %s Set the display window (e.g., 1920x1080, 1024x768+100+0, -20-30) .TP .B \-\-fullpixels Set the 'full' image range to be the pixel data window .TP .BI \-\-chnames\ %s Set the channel names (comma-separated) .SS Options that affect subsequent actions: .TP .BI \-\-fail\ %g Failure threshold difference (0.000001) .TP .BI \-\-failpercent\ %g Allow this percentage of failures in diff (0) .TP .BI \-\-hardfail\ %g Fail diff if any one pixel exceeds this error (infinity) .TP .BI \-\-warn\ %g Warning threshold difference (0.00001) .TP .BI \-\-warnpercent\ %g Allow this percentage of warnings in diff (0) .TP .BI \-\-hardwarn\ %g Warn if any one pixel difference exceeds this error (infinity) .SS Actions: .TP .BI \-\-create\ %s\ %d Create a blank image (args: geom, channels) .TP .BI \-\-pattern\ %s\ %s\ %d Create a patterned image (args: pattern, geom, channels) .TP .BI \-\-kernel\ %s\ %s Create a centered convolution kernel (args: name, geom) .TP .B \-\-capture Capture an image (options: camera=%d) .TP .B \-\-diff Print report on the difference of two images (modified by --fail, --failpercent, --hardfail, --warn, --warnpercent --hardwarn) .TP .B \-\-add Add two images .TP .B \-\-sub Subtract two images .TP .B \-\-abs Take the absolute value of the image pixels .TP .B \-\-mul Multiply two images .TP .BI \-\-cmul\ %s Multiply the image values by a scalar or per-channel constants (e.g.: 0.5 or 1,1.25,0.5) .TP .BI \-\-cadd\ %s Add to all channels a scalar or per-channel constants (e.g.: 0.5 or 1,1.25,0.5) .TP .B \-\-chsum Turn into 1-channel image by summing channels (options: weight=r,g,...) .TP .BI \-\-paste\ %s Paste fg over bg at the given position (e.g., +100+50) .TP .BI \-\-mosaic\ %s Assemble images into a mosaic (arg: WxH; options: pad=0) .TP .B \-\-over \&'Over' composite of two images .TP .B \-\-zover Depth composite two images with Z channels (options: zeroisinf=%d) .TP .BI \-\-histogram\ %s\ %d Histogram one channel (options: cumulative=0) .TP .B \-\-flip Flip the image vertically (top<->bottom) .TP .B \-\-flop Flop the image horizontally (left<->right) .TP .B \-\-flipflop Flip and flop the image (180 degree rotation) .TP .B \-\-transpose Transpose the image .TP .BI \-\-cshift\ %s Circular shift the image (e.g.: +20-10) .TP .BI \-\-crop\ %s Set pixel data resolution and offset, cropping or padding if necessary (WxH+X+Y or xmin,ymin,xmax,ymax) .TP .B \-\-croptofull Crop or pad to make pixel data region match the "full" region .TP .BI \-\-resample\ %s Resample (640x480, 50%) .TP .BI \-\-resize\ %s Resize (640x480, 50%) (optional args: filter=%s) .TP .BI \-\-fit\ %s Resize to fit within a window size (optional args: filter=%s, pad=%d) .TP .B \-\-convolve Convolve with a kernel .TP .BI \-\-blur\ %s Blur the image (arg: WxH; options: kernel=name) .TP .B \-\-unsharp Unsharp mask (options: kernel=gaussian, width=3, contrast=1, threshold=0) .TP .B \-\-fft Take the FFT of the image .TP .B \-\-ifft Take the inverse FFT of the image .TP .BI \-\-fixnan\ %s Fix NaN/Inf values in the image (options: none, black, box3) .TP .B \-\-fillholes Fill in holes (where alpha is not 1) .TP .BI \-\-fill\ %s Fill a region (options: color=) .TP .B \-\-clamp Clamp values (options: min=..., max=..., clampalpha=0) .TP .B \-\-rangecompress Compress the range of pixel values > 1 with a log scale (options: luma=0|1) .TP .B \-\-rangeexpand Un-rangecompress pixel values > 1 (options: luma=0|1) .TP .BI \-\-text\ %s Render text into the current image (options: x=, y=, size=, color=) .SS Image stack manipulation: .TP .BI \-\-ch\ %s Select or shuffle channels (e.g., "R,G,B", "B,G,R", "2,3,4") .TP .B \-\-chappend Append the channels of the last two images .TP .B \-\-unmip Discard all but the top level of a MIPmap .TP .BI \-\-selectmip\ %d Select just one MIP level (0 = highest res) .TP .BI \-\-subimage\ %d Select just one subimage .TP .B \-\-pop Throw away the current image .TP .B \-\-dup Duplicate the current image (push a copy onto the stack) .TP .B \-\-swap Swap the top two images on the stack. .SS Color management: .TP .BI \-\-iscolorspace\ %s Set the assumed color space (without altering pixels) .TP .BI \-\-tocolorspace\ %s Convert the current image's pixels to a named color space .TP .BI \-\-colorconvert\ %s\ %s Convert pixels from 'src' to 'dst' color space (without regard to its previous interpretation) .TP .BI \-\-ociolook\ %s Apply the named OCIO look (optional args: from=, to=, inverse=, key=, value=) .TP .B \-\-unpremult Divide all color channels of the current image by the alpha to "un-premultiply" .TP .B \-\-premult Multiply all color channels of the current image by the alpha .PP Known color spaces: "linear", "sRGB", "Rec709" .SH SEE ALSO .BR iconvert (1), .BR idiff (1), .BR igrep (1), .BR iinfo (1), .BR iv (1), .BR maketx (1). .SH AUTHOR OpenImageIO was written by Larry Gritz and the other authors and contributors. .PP This manual page was written by IRIE Shinsuke , for the Debian project (and may be used by others).