1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Raw convertion parameters</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<h1>Raw convertion parameters</h1>
This page gives some details about the raw image format conversion process that takes place in LuminanceHDR.
<ol>
<li><A href="#intro">Introduction</A></li>
<li><A href="#tweak">Tweaking the conversion process</A></li>
<li><A href="#excerpt">Dcraw manual page excerpt</A></li>
<li><A href="#links">Links</A></li>
</ol>
<A name="intro"><h2>Introduction</h2></A>
<p>
Each time the user:
<ul>
<li>loads a single raw file in the main workspace</li>
<li>specifies a set of raw files in the "File -> New Hdr..." wizard</li>
</ul>
a RAW->TIFF conversion transparently takes place by calling the dcraw [1] executable (by Dave Coffin).<br>
LuminanceHDR calls dcraw to convert a raw file [2] to a (either 8 bit or 16 bit) TIFF file.<br>
<A name="tweak"><h2>Tweaking the conversion process</h2></A>
You can tweak the way dcraw operates by setting specific command line switches (aka options or parameters) in the <em>Tools -> Preferences... -> Raw Import</em> section (here's a screenshot).<br>
<img src="images/raw_conversion.jpg" width="483" height="480"><br>
The -T switch (TIFF output, see <A href="#excerpt">below</A>) is the only required parameter.<br>
In this particular case we have also specified the optional -4 parameter to ask dcraw to obtain a 16 bit (TIFF) file.<br>
Starting with LuminanceHDR 1.9.3 the default options for calling dcraw are -T -4 -q 3.<br>
The dcraw's manual page lists all the available options.<br>
An excerpt is available <A href="#excerpt">below</A>, for the latest manual page follow this reference [3].<br>
<A name="excerpt"><h2>Dcraw manual page excerpt</h2></A>
Here's an excerpt from dcraw's man page (Retrieved: October 30, 2007).</p>
<pre>
OPTIONS
-v
Print verbose messages, not just warnings and errors.
-c
Write decoded images or thumbnails to standard output.
-e
Extract the camera-generated thumbnail, not the raw image. You'll get either a JPEG or a PPM file, depending on the camera.
-z
Change the access and modification times of an AVI, JPEG, TIFF or raw file to when the photo was taken, assuming that the camera clock was set to Universal Time.
-i
Identify files but don't decode them. Exit status is 0 if dcraw can decode the last file, 1 if it can't. -i -v shows metadata.
dcraw cannot decode JPEG files!!
-d
Show the raw data as a grayscale image with no interpolation. Good for photographing black-and-white documents.
-D
Same as -d, but totally raw (no color scaling).
-h
Output a half-size color image. Twice as fast as -q 0.
-q 0
Use high-speed, low-quality bilinear interpolation.
-q 1
Use Variable Number of Gradients (VNG) interpolation.
-q 2
Use Patterned Pixel Grouping (PPG) interpolation.
-q 3
Use Adaptive Homogeneity-Directed (AHD) interpolation.
-f
Interpolate RGB as four colors. Use this if the output shows false 2x2 meshes with VNG or mazes with AHD.
-m number_of_passes
After interpolation, clean up color artifacts by repeatedly applying a 3x3 median filter to the R-G and B-G channels.
-n noise_threshold
Use wavelets to erase noise while preserving real detail. The best threshold should be somewhere between 100 and 1000.
-b brightness
By default, dcraw writes 8-bit PGM/PPM/PAM with a BT.709 gamma curve and a 99th-percentile white point. If the result is too light or too dark, -b lets you adjust it. Default is 1.0.
-4
Write 16-bit linear pseudo-PGM/PPM/PAM with no gamma curve, no white point, and no -b option.
-T
Write TIFF output (with metadata) instead of PGM/PPM/PAM.
-k black
Set the black point. Default depends on the camera.
-K darkframe.pgm
Subtract a dark frame from the raw data. To generate a dark frame, shoot a raw photo with no light and do dcraw -D -4 -j -t 0.
-w
Use the white balance specified by the camera. If this is not found, print a warning and use another method.
-a
Calculate the white balance by averaging the entire image.
-A left top width height
Calculate the white balance by averaging a rectangular area. First do dcraw -j -t 0 and select an area of neutral grey color.
-r mul0 mul1 mul2 mul3
Specify your own raw white balance. These multipliers can be cut and pasted from the output of dcraw -v.
no white balance option
Use a fixed white balance based on a color chart illuminated with a standard D65 lamp.
+M or -M
Use (or don't use) any color matrix from the camera metadata. The default is +M if -w is set, -M otherwise. This option only affects Olympus, Leaf, and Phase One cameras.
-C red_mag blue_mag
Enlarge the raw red and blue layers by the given factors, typically 0.999 to 1.001, to correct chromatic aberration.
-H 0
Clip all highlights to solid white (default).
-H 1
Leave highlights unclipped in various shades of pink.
-H 2
Blend clipped and unclipped values together for a gradual fade to white.
-H 3-9
Reconstruct highlights. Low numbers favor whites; high numbers favor colors. Try -H 5 as a compromise. If that's not good enough, do -H 9, cut out the non-white highlights, and paste them into an image generated with -H 3.
-o [0-5]
Select the output colorspace when the -p option is not used:
0 Raw color (unique to each camera)
1 sRGB D65 (default)
2 Adobe RGB (1998) D65
3 Wide Gamut RGB D65
4 Kodak ProPhoto RGB D65
5 XYZ
-p camera.icm [ -o output.icm ]
Use ICC profiles to define the camera's raw colorspace and the desired output colorspace (sRGB by default).
-p embed
Use the ICC profile embedded in the raw photo.
-t [0-7,90,180,270]
Flip the output image. By default, dcraw applies the flip specified by the camera. -t 0 disables all flipping.
-s [0..N-1] or -s all
If a file contains N raw images, choose one or "all" to decode. For example, Fuji Super CCD SR cameras generate a second image underexposed four stops to show detail in the highlights.
-j
For Fuji Super CCD cameras, show the image tilted 45 degrees. For cameras with non-square pixels, do not stretch the image to its correct aspect ratio. In any case, this option guarantees that each output pixel corresponds to one raw pixel.
</pre>
<A name="links"><h2>Links</h2></A>
<pre>
[1]http://cybercom.net/~dcoffin/dcraw/
[2]http://en.wikipedia.org/wiki/Raw_image_format
[3]http://cybercom.net/~dcoffin/dcraw/dcraw.1.html
</pre>
</body>
</html>
|