1dcraw(1)                    General Commands Manual                   dcraw(1)
2
3
4

NAME

6       dcraw - command-line decoder for raw digital photos
7

SYNOPSIS

9       dcraw [OPTION]... [FILE]...
10

DESCRIPTION

12       dcraw decodes raw photos, displays metadata, and extracts thumbnails.
13

GENERAL OPTIONS

15       -v     Print verbose messages, not just warnings and errors.
16
17       -c     Write decoded images or thumbnails to standard output.
18
19       -e     Extract  the  camera-generated  thumbnail,  not  the  raw image.
20              You'll get either a JPEG or a PPM file, depending on the camera.
21
22       -z     Change the access and modification times of an AVI,  JPEG,  TIFF
23              or  raw file to when the photo was taken, assuming that the cam‐
24              era clock was set to Universal Time.
25
26       -i     Identify files but don't decode them.  Exit status is 0 if dcraw
27              can decode the last file, 1 if it can't.  -i -v shows metadata.
28
29              dcraw cannot decode JPEG files!!
30

REPAIR OPTIONS

32       -P deadpixels.txt
33              Read the dead pixel list from this file instead of ".badpixels".
34              See FILES for a description of the format.
35
36       -K darkframe.pgm
37              Subtract a dark frame from the raw data.   To  generate  a  dark
38              frame,    shoot   a   raw   photo   with   no   light   and   do
39              dcraw -D -4 -j -t 0.
40
41       -k darkness
42              When shadows appear foggy, you need to raise the darkness level.
43              To measure this, apply pamsumm -mean to the dark frame generated
44              above.
45
46       -S saturation
47              When highlights appear pink, you need to  lower  the  saturation
48              level.   To  measure this, take a picture of something shiny and
49              do dcraw -D -4 -j -c photo.raw | pamsumm -max
50
51              The default darkness and saturation are usually correct.
52
53       -n noise_threshold
54              Use wavelets to erase noise while preserving real  detail.   The
55              best threshold should be somewhere between 100 and 1000.
56
57       -C red_mag blue_mag
58              Enlarge  the raw red and blue layers by the given factors, typi‐
59              cally 0.999 to 1.001, to correct chromatic aberration.
60
61       -H 0   Clip all highlights to solid white (default).
62
63       -H 1   Leave highlights unclipped in various shades of pink.
64
65       -H 2   Blend clipped and unclipped values together for a  gradual  fade
66              to white.
67
68       -H 3+  Reconstruct  highlights.  Low numbers favor whites; high numbers
69              favor colors.  Try -H 5 as a compromise.   If  that's  not  good
70              enough,  do  -H 9,  cut  out the non-white highlights, and paste
71              them into an image generated with -H 3.
72

COLOR OPTIONS

74       By default, dcraw uses a fixed white balance based  on  a  color  chart
75       illuminated with a standard D65 lamp.
76
77       -w     Use  the  white balance specified by the camera.  If this is not
78              found, print a warning and use another method.
79
80       -a     Calculate the white balance by averaging the entire image.
81
82       -A left top width height
83              Calculate the white balance by  averaging  a  rectangular  area.
84              First do dcraw -j -t 0 and select an area of neutral grey color.
85
86       -r mul0 mul1 mul2 mul3
87              Specify  your  own  raw white balance.  These multipliers can be
88              cut and pasted from the output of dcraw -v.
89
90       +M or -M
91              Use (or don't use) any color matrix from  the  camera  metadata.
92              The  default is +M if -w is set, -M otherwise.  This option only
93              affects Olympus, Leaf, and Phase One cameras.
94
95       -o [0-5]
96              Select the output colorspace when the -p option is not used:
97
98                   0   Raw color (unique to each camera)
99                   1   sRGB D65 (default)
100                   2   Adobe RGB (1998) D65
101                   3   Wide Gamut RGB D65
102                   4   Kodak ProPhoto RGB D65
103                   5   XYZ
104
105       -p camera.icm [ -o output.icm ]
106              Use ICC profiles to define the camera's raw colorspace  and  the
107              desired output colorspace (sRGB by default).
108
109       -p embed
110              Use the ICC profile embedded in the raw photo.
111

INTERPOLATION OPTIONS

113       -d     Show  the  raw  data as a grayscale image with no interpolation.
114              Good for photographing black-and-white documents.
115
116       -D     Same as -d, but totally raw (no color scaling).
117
118       -h     Output a half-size color image.  Twice as fast as -q 0.
119
120       -q 0   Use high-speed, low-quality bilinear interpolation.
121
122       -q 1   Use Variable Number of Gradients (VNG) interpolation.
123
124       -q 2   Use Patterned Pixel Grouping (PPG) interpolation.
125
126       -q 3   Use Adaptive Homogeneity-Directed (AHD) interpolation.
127
128       -f     Interpolate RGB as four colors.  Use this if  the  output  shows
129              false 2x2 meshes with VNG or mazes with AHD.
130
131       -m number_of_passes
132              After  interpolation,  clean  up  color  artifacts by repeatedly
133              applying a 3x3 median filter to the R-G and B-G channels.
134

OUTPUT OPTIONS

136       By default, dcraw writes PGM/PPM/PAM with 8-bit samples, a BT.709 gamma
137       curve, a histogram-based white level, and no metadata.
138
139       -W     Use a fixed white level, ignoring the image histogram.
140
141       -b brightness
142              Divide the white level by this number, 1.0 by default.
143
144       -g power toe_slope
145              Set  the  gamma curve, by default BT.709 (-g 2.222 4.5).  If you
146              prefer sRGB gamma, use -g 2.4 12.92.  For a simple power  curve,
147              set the toe slope to zero.
148
149       -6     Write sixteen bits per sample instead of eight.
150
151       -4     Linear 16-bit, same as -6 -W -g 1 1.
152
153       -T     Write TIFF with metadata instead of PGM/PPM/PAM.
154
155       -t [0-7,90,180,270]
156              Flip the output image.  By default, dcraw applies the flip spec‐
157              ified by the camera.  -t 0 disables all flipping.
158
159       -j     For Fuji Super CCD cameras, show the image  tilted  45  degrees.
160              For  cameras with non-square pixels, do not stretch the image to
161              its correct aspect ratio.  In any case, this  option  guarantees
162              that each output pixel corresponds to one raw pixel.
163
164       -s [0..N-1] or -s all
165              If  a file contains N raw images, choose one or "all" to decode.
166              For example, Fuji Super CCD SR cameras generate a  second  image
167              underexposed four stops to show detail in the highlights.
168

FILES

170       ./.badpixels, ../.badpixels, ../../.badpixels, ...
171              List of your camera's dead pixels, so that dcraw can interpolate
172              around them.  Each line specifies the column, row, and UNIX time
173              of death for one pixel.  For example:
174
175               962   91 1028350000  # died between August 1 and 4, 2002
176              1285 1067 0           # don't know when this pixel died
177
178              These  coordinates  are  before any cropping or rotation, so use
179              dcraw -j -t 0 to locate dead pixels.
180

SEE ALSO

182       pgm(5), ppm(5), pam(5),  pamsumm(1),  pnmgamma(1),  pnmtotiff(1),  pnm‐
183       topng(1), gphoto2(1), cjpeg(1), djpeg(1)
184

AUTHOR

186       Written by David Coffin, dcoffin a cybercom o net
187
188
189
190                                 May 14, 2009                         dcraw(1)
Impressum