Section: User Commands (1)Local indexUp BSD mandoc
- Convert Minolta DiMAGE 5/7/7Hi/7i/A1 RAW images to PPM
[-wb name | rgain : ggain : bgain
converts a Minolta DiMAGE 5/7/7i/7Hi/A1 RAW image read from its standard input
into a PPM image which is written to its standard output.
first processes the system wide parameter file
Entries in this file (if it exists) will override the compiled defaults.
then processes the user's parameter file
if it exists.
Entries in this file will override both compiled defaults
and entries in the system wide parameter file.
then processes command line options,
which if given will override compiled values and values set in the initialization
The program will then read a mrw file from its standard input,
convert it as specified, and write a PPM file to its standard output.
PROCESSING AND OPTIONS
The pixels input from the .mrw file are color corrected.
The algorithm is to multiply the input pixels by gain values for each color.
The default color balance is "camera", which uses the color balance data
the camera stored in the mrw file.
Overrides the default color balance.
The following color balances are known to mrwtoppm:
camera, daylight, flash, cloudy, tungsten, flourescent, none, and preset6.
None does not balance the colors.
The other color balances are camera specific and are obtained from data
stored in the mrw file. Preset6 is a stored preset the meaning of which
is currently unknown.
-wb rgain : ggain : bgain
Manually override color balance.
Red, green and blue pixel values are multiplied by
rgain /256,ggain /256 andbgain /256 respectively.
By default, color balances other than those listed above are searched for
in the following path list:
This list can be changed using this option.
The image is rotated by 0, 90, 180, or 270 degrees.
Rotate image clockwise by
The default is 0.
The angle must be one of the above four values.
The image can be optionally be scaled by an even factor (N).
When the image is scaled
bayer pattern interpolation is not performed and
output pixels are calculated simply by averaging the same color pixels
in N by N input blocks.
If the scale does not evenly divide the image size (that is, for scales
other than 1, 2, 4, and 8) the final image size is rounded down, and the
excess input pixels are ignored. The selected pixels are centered on the
image center. The intent is to allow high-speed image preview.
Divide image height and width each by
Legal values are 1 (default, no scaling), 1/N for even N.
A dark field image, if any, is subtracted from the image data.
The dark field image must be an mrw file the same size as the image data.
It should be an image taken with the same ISO and shutter speed as the image, but with the lens covered.
The intent is subtract the CCD "noise" caused by long exposure times.
Default is none.
The dark field image is looked for in a file
Qq Ar name Ns .mrw
in the dark field path.
If the image is not scaled, the Bayer pattern data is interpolated.
The following algorithms are implemented:
The vector median algorithm of Gupta and Chen (default).
A simple bilinear interpolation scheme (faster but much lower quality).
Select the interpolation method to use:
bilinear, vmedian (default), mgbrb, mgmrb.
Vector median interpolation and filtering is done in CIELab color space (default).
Vector median interpolation and filtering is done in the camera's color space
Sets the error tolerance for the vector median algorithm (larger is faster, but lower quality).
The default is fairly high quality.
A median of medians filter may be applied.
Apply median of medians filter.
Do not apply median of medians filter (default).
The image's tone curve is adjusted.
Apply the named tone curve.
Default is "minolta".
The tone curve "none" is just that.
Set the tone curve search path.
The default tone curve search path is
An additional vector median filtering step may be performed.
Apply additional vector median filter.
Do not apply additional vector median filter (default)
The image may be sharpened or blurred.
In Lab mode, the luminance and chrominance channels can be sharpened/blurred independently.
Sharpening is done by unsharp masking.
Determine convolution matrix used for blurring
This is a 3x3 matrix having the following values:
1 1/val 1
1/val 1/val^2 1/val
1 1/val 1
The matrix is scaled so that the matrix elements sum to 1.
Larger values cause more blurring.
Default is 0.5.
Sharpen pixels by
times the difference between the original and blurred values.
Negative values blur the image.
An amt of -1 replaces the pixel with the blurred pixel generated above.
In Lab mode, only the L channel is affected.
In RGB mode, all channels are affected.
Default is 2.
In Lab mode only, sharpen/blur the two chrominance channels by
Default is -1.
The image is converted from the camera's color space into the output color space.
The former defaults to the camera's color space, the latter to sRGB.
Overrides the default camera profile.
Overrides the default output profile.
Set the profile search path.
The default tone curve search path is
The image is further gamma corrected and contrast stretched.
Overrides the default gamma factor to correct for.
The default gamma to correct for is 1 (meaning no change).
Override the default contrast setting.
The image is contrast stretched so that the
val /2000 largest color values and the val /2000 smallest color values are output as the maximum or minimum value respectively.
The default is 1.
If the contrast value is 0, the color values are only scaled such that the largest value is output as the maximum value.
If the contrast value is negative, no contrast stretching is done.
The image is output as a raw PPM file or as an xv thumbnail.
The output file can contain either 8 or 16 bits per color per pixel.
Output an 8 bit/color/pixel PPM file (default).
Output a 16 bit/color/pixel PPM file.
Output an xv thumbnail file (8 bits total per pixel: 3 red, 3 green, 2 blue).
Legal thumbnail files must be no larger than 80x80. The user is responsible for
selecting a suitable scale factor for achieving this.
The initialization file consist of a sequence of lines.
Each line sets one option.
Option names are the same as the command line options,
except that the leading dash
Options that take a parameter have the form
option = value
Options that do not have a parameter have the form
(the need for the = is a bug that will get squished later).
Location of colormaps used for color balance correction.
Location of camera profiles used for color space conversion.
Location of tone curves used for tone curve adjustment.
Neither this program nor any others in the package take image files as
parameters. They all read the image from the standard input and write
their results (a PPM file in this case) to standard output. Unfortunately,
this causes new users lots of grief.