Difference between revisions of "Enfuse"

From PanoTools.org Wiki
Jump to navigation Jump to search
m (→‎Known bugs: unified structure)
m (Reverted edits by Ipodsoft (talk) to last revision by Erik Krause)
(45 intermediate revisions by 9 users not shown)
Line 1: Line 1:
 
[[Image:2125768589_b.jpg|thumb|[[:Image:2125768589_b.jpg|Four exposure panorama blended with enfuse]]]]
 
[[Image:2125768589_b.jpg|thumb|[[:Image:2125768589_b.jpg|Four exposure panorama blended with enfuse]]]]
 +
[[Image:Lamp_enfuse.jpg|thumb|[[:Image:Lamp_enfuse.jpg|17 EV image blended with enfuse - (c) Jacek Zagaja]]]]
 
Enfuse is {{glossary|a command-line program used to merge different exposures of the same scene to produce an image that looks very much like a [[Tone_mapping|tonemapped]] image (without the [[Halo|halos]]) but requires no creation of an [[HDR]] image|1}}. Therefore it is much simpler to use and allows the creation of very large multiple exposure panoramas.
 
Enfuse is {{glossary|a command-line program used to merge different exposures of the same scene to produce an image that looks very much like a [[Tone_mapping|tonemapped]] image (without the [[Halo|halos]]) but requires no creation of an [[HDR]] image|1}}. Therefore it is much simpler to use and allows the creation of very large multiple exposure panoramas.
  
 
Enfuse is based on a paper by Tom Mertens, Jan Kautz and Frank Van Reeth: [http://research.edm.uhasselt.be/~tmertens/papers/exposure_fusion_reduced.pdf "Exposure fusion"] The implementation was done by Andrew Mihal (developer of [[Enblend]]) and the [[hugin]] team around [[User:Pablo|Pablo d'Angelo]]
 
Enfuse is based on a paper by Tom Mertens, Jan Kautz and Frank Van Reeth: [http://research.edm.uhasselt.be/~tmertens/papers/exposure_fusion_reduced.pdf "Exposure fusion"] The implementation was done by Andrew Mihal (developer of [[Enblend]]) and the [[hugin]] team around [[User:Pablo|Pablo d'Angelo]]
 +
 +
An extended documentation could be found on [[Enfuse reference manual]]
 +
 +
Other programs using Exposure Fusion: [http://www.tawbaware.com/tufuse.htm tufuse] and [[PTGui]] Pro
  
 
== State of development ==
 
== State of development ==
Enfuse is currently in beta and available with the development version of [[Enblend]] from [http://panospace.wordpress.com/downloads/ panospace.wordpress] (scroll down on that page).
+
On 8 September 2008 the first official version of enfuse has been released together with enblend.
 +
Enfuse/enblend can be downloaded from [http://enblend.sourceforge.net/ enblend.sourceforge.net]. On that site you will find the 3.2 version source code as well as precompiled windows binaries.
 +
 
 +
Beta (development) releases can be downloaded from  
 +
*[http://panorama.dyndns.org/index.php?lang=en&subject=Hugin&texttag=Hugin panorama.dyndns.org] (scroll down on that page) for MacOSX
 +
*and also from [http://hugin.panotools.org/testing/hugin/ hugin.panotools.org]
  
 
=== Known bugs ===
 
=== Known bugs ===
* '''Windows version only''': if used on too many and/or too large files enfuse terminates with an error message: <code>an exception occured [...] unable to create image swap file</code>
+
(This section needs to be updated)<br>
:: - fixed in version linked above
+
This is a list of known bugs in the current version as linked above. For a list of bugs in previous versions please refer to an [http://wiki.panotools.org/Enfuse?oldid=10011 older version of this page]
 
 
* If used on images with unaligned alpha mask (result of aligning handheld shots) there might be colored or dark spots.
 
: Workaround: crop the aligned images.
 
:: - fixed in version linked above
 
  
 
* If contrasty structures are near [[zenith]] or [[nadir]] in an [[equirectangular]] image, there might be an artifact (vortex) in the resulting pano.
 
* If contrasty structures are near [[zenith]] or [[nadir]] in an [[equirectangular]] image, there might be an artifact (vortex) in the resulting pano.
Line 19: Line 25:
 
:: - unknown, whether could be fixed easily
 
:: - unknown, whether could be fixed easily
  
* actually not a bug: Default compression for [[JPEG]] output is relatively low.
+
== Description ==
: Workaround: Specify <code>--compression=100</code> on the command line if you need JPEG output.
+
Enfuse merges overlapping images using the Mertens-Kautz-Van Reeth exposure fusion algorithm. This is a quick way to blend differently exposed images into a nice output image, without producing intermediate [[HDR]] images that are then tonemapped to a viewable image. This simplified process often works much better than the currently known tonemapping algorithms.
:: - fixed in version linked above (defaults to 98)
 
  
* [[wikipedia:LZW|LZW]] compression for [[TIFF]] files is not supported if an older version of libtiff has been used. For various reasons most/all existing Windows binaries have this problem (Jan 2008).
+
Enfuse can also be used to build extended [[Depth_of_Field|DOF]] images, by blending a focus stack.
: Workaround: use [[wikipedia:DEFLATE|DEFLATE]] (ZIP) compression instead.
 
:: - fixed in version linked above
 
  
* A slight seam (brightness difference) along the 360° joint of an [[equirectangular]] panorama, if there was a contrasty structure near the edge, even if the -w option was used.
+
=== Basics ===
: Workaround: use enfuse before stitching.
+
The basic idea is that pixels in the input images are weighted according to qualities such as proper exposure, good contrast, and high saturation. These weights determine how much a given pixel will contribute to the final image.  
:: - fixed in version linked above
 
  
== Description ==
+
This idea is not quite new. F.e. Ardeshir Goshtasby proposed a [http://www.humanfactors.wright.edu/~agoshtas/IMAVIS4.27.Paper.pdf technique to select and blend only well exposed blocks] and Erik Krause provided a [http://www.erik-krause.de/blending photoshop action] to smart mask badly exposed areas. Many such "DRI" or "Exposure Blending" solutions exist.
Enfuse merges overlapping images using the Mertens-Kautz-Van Reeth exposure fusion algorithm. This is a quick way to produce blend differently exposed images into a nice output image, without producing intermediate [[HDR]] images that are then tonemapped to a viewable image. This simplified process often works much better than the currently known tonemapping algorithms.
 
  
Enfuse can also be used to build extended [[Depth_of_Field|DOF]] images, by blending a focus stack.
+
The problem of all this techniques was to find good transitions between the areas taken from differently exposed images. There always was a risk of getting banding or even reversed gradients within areas where the brightness gradually changed.
  
The basic idea is that pixels in the input images are weighted according to qualities such as proper exposure, good contrast, and high saturation. These weights determine how much a given pixel will contribute to the final image. A Burt & Adelson multiresolution spline blender is used to combine the images according to the weights. The multiresolution blending ensures that transitions between regions where different images contribute more heavily are difficult to see.
+
Enfuse solves this problem by using the multi resolution spline blending technique well known from [[enblend]] and [[smartblend]] - and it is actually this step which is responsible for the wonderful results. The technique is described detailed [http://enblend.sourceforge.net/details.htm for enblend] and it works almost the same for enfuse, with the exception that instead of the initial seam line a mask is created according to the given criteria.  
  
Enfuse uses three different criteria to judge the quality of a pixel: Exposure, saturation, and contrast. The exposure criteria favors pixels with luminance close to the middle of the range. These pixels are considered better-exposed than those with high or low luminance levels. The saturation criteria favors highly-saturated pixels. The contrast criteria favors high-contrast pixels. The local gray or color value standard deviation is used as a contrast measure. The Mertens-Kautz-Van Reeth paper suggest using a laplacian filter, but the standard deviation produces much better results for differently focussed images.
+
Enfuse uses three different criteria to judge the quality of a pixel: Exposure, saturation, and contrast.  
 +
* The exposure criteria favors pixels with luminance close to the middle of the range. These pixels are considered better-exposed than those with high or low luminance levels.  
 +
* The saturation criteria favors highly-saturated pixels.  
 +
* The contrast criteria favors high-contrast pixels. The local gray or color value standard deviation is used as a contrast measure. The Mertens-Kautz-Van Reeth paper suggest using a laplacian filter, but the standard deviation produces much better results for differently focused images.
  
 +
=== Adjustments ===
 
You can adjust how much importance is given to each criteria by setting the weight parameters on the command line. For example, if you set --wExposure=1.0 and --wSaturation=0.5, Enfuse will favor well-exposed pixels over highly-saturated pixels when blending the source images. The impact of these parameters on the final result will not always be clear. The quality of the result is subject to your artistic interpretation. Playing with the weights may or may not give you a more pleasing result. I encourage you to experiment (perhaps using downsized images for speed).
 
You can adjust how much importance is given to each criteria by setting the weight parameters on the command line. For example, if you set --wExposure=1.0 and --wSaturation=0.5, Enfuse will favor well-exposed pixels over highly-saturated pixels when blending the source images. The impact of these parameters on the final result will not always be clear. The quality of the result is subject to your artistic interpretation. Playing with the weights may or may not give you a more pleasing result. I encourage you to experiment (perhaps using downsized images for speed).
  
Enfuse expects each input image to have an alpha channel. By setting the alpha values of pixels to zero, users can manually remove those pixels from consideration when blending. If an input image lacks an alpha channel, Enfuse will print a warning and continue assuming all pixels should contribute to the final output. Any alpha value other than zero is interpreted as "this pixel should contribute to the final image".
+
Enfuse allows each input image to have an alpha channel. By setting the alpha values of pixels to zero, users can manually remove those pixels from consideration when blending. If an input image lacks an alpha channel, Enfuse will print a warning and continue assuming all pixels should be processed for final output. Any alpha value other than zero is interpreted as "this pixel should should be considered for the final image".
  
 
== Usage ==
 
== Usage ==
Line 50: Line 55:
  
 
=== Common options ===
 
=== Common options ===
 
 
  -h
 
  -h
 
Print information on the available options.  
 
Print information on the available options.  
 
  -l num
 
  -l num
Use exactly this many levels for pyramid blending. A low number trades off quality of results for faster execution time and lower memory usage. The default is to use as many levels as possible given the source image size. If you specify a high number Enfuse may still use a smaller number of levels if the geometry of the images demands it.  
+
Use exactly this many levels for pyramid blending. A low number trades off quality of results for faster execution time and lower memory usage. The default is to use as many levels as possible given the source image size. However, recent versions don't seem to do that hence it might be useful to specify an arbitrary high number (f.e. -l 20) for best results. If you specify a high number Enfuse may still use a smaller number of levels if the geometry of the images demands it.  
 
  -o output-file
 
  -o output-file
 
Required. Specify the name of the output file.  
 
Required. Specify the name of the output file.  
Line 62: Line 66:
 
Blend around the -180/+180 boundary. Useful for full-360 panoramas. Enfuse currently does not blend the zenith or the nadir, so you may still see some seams in these areas.  
 
Blend around the -180/+180 boundary. Useful for full-360 panoramas. Enfuse currently does not blend the zenith or the nadir, so you may still see some seams in these areas.  
 
  --compression=COMP
 
  --compression=COMP
Write a compressed output file. Valid values are [[LZW]] and [[DEFLATE]] for TIFF files, and numbers from 0-100 for JPEG files.
+
Write a compressed output file. Valid values are [[w:NONE|NONE]], [[w:PACKBITS|PACKBITS]], [[w:LZW|LZW]] and [[w:DEFLATE|DEFLATE]] for TIFF files, and numbers from 0-100 for JPEG files.
  
 
=== Extended options ===
 
=== Extended options ===
Line 75: Line 79:
 
Set the size and position of the output image manually. This is useful when the input images are cropped TIFF files, such as those produced by Nona.  
 
Set the size and position of the output image manually. This is useful when the input images are cropped TIFF files, such as those produced by Nona.  
 
  -m megabytes
 
  -m megabytes
Set the size of Enfuse's image cache. This is the amount of memory Enfuse will use for storing image data before swapping to disk. The default is 1 GiB.
+
Set the size of Enfuse's image cache. This is the amount of RAM (in megabytes) Enfuse will use for storing image data before swapping to disk. The default is 1024 MB.
  
 
=== Fusion options ===
 
=== Fusion options ===
 
<code>W</code> is a number between 0 (no weight) and 1 (full weight)
 
<code>W</code> is a number between 0 (no weight) and 1 (full weight)
 
  --wExposure=W
 
  --wExposure=W
Sets the relative weight of the well-exposedness criteria. Increasing this weight relative to the others will make well-exposed pixels contribute more to the final output.  
+
Sets the relative weight of the well-exposedness criterion. Increasing this weight relative to the others will make well-exposed pixels contribute more to the final output.  
 
  --wSaturation=W
 
  --wSaturation=W
 
Sets the relative weight of high-saturation pixels. Increasing this weight makes pixels with high saturation contribute more to the final output.  
 
Sets the relative weight of high-saturation pixels. Increasing this weight makes pixels with high saturation contribute more to the final output.  
 
  --wContrast=W
 
  --wContrast=W
Sets the relative weight of high-contrast pixels.
+
Sets the relative weight of high-contrast pixels. Increasing this weight makes pixels with neighboring differently colored pixels contribute more to the final output. Particularly useful for focus stacks.
 +
--wMu=mu
 +
Mean of the gaussian weighting function (from 0 to 1) for the exposure criterion only. default value: 0.5. This moves the peak of the curve towards the brighter or darker end of the [[histogram]]. Higher values pick more brighter pixels from the source images, lower values more darker ones.
 +
--wSigma=sigma
 +
Standard deviation of the gaussian weighting function (from 0) for the exposure criterion only. default value: 0.2. Higher values cause a wider curve and more pixels to be taken from a particular image (possibly including under- and over-exposed ones). A lower value causes a narrower curve and less pixels to be taken, possibly resulting in banding.
 +
--HardMask
 +
Force hard blend masks on the finest scale. This avoids averaging of fine details (only), at the expense of increasing the noise. This improves the sharpness of focus stacks considerably.
  
 
=== Expert options ===
 
=== Expert options ===
Line 91: Line 101:
 
Window size for local contrast analysis. Values larger than 5 might result in increased computation times. Values in the range of 3 to 7 have given good results on focus stacks. The impact on the result quality is not easy to define. You will have to experiment.
 
Window size for local contrast analysis. Values larger than 5 might result in increased computation times. Values in the range of 3 to 7 have given good results on focus stacks. The impact on the result quality is not easy to define. You will have to experiment.
  
  --HardMask
+
  --GrayProjector=OPERATOR
Force hard blend masks on the finest scale. This avoids averaging of fine details (only), at the expense of increasing the noise. This improves the sharpness of focus stacks considerably.
+
Apply grayscale projection OPERATOR, where OPERATOR is one of "average", "l-star", "lightness", "value", "luminance", or          "channel-mixer:RED-WEIGHT:GREEN-WEIGHT:BLUE-WEIGHT". Default: "average"
 +
 
 +
--EdgeScale=EDGESCALE[:LCESCALE[:LCEFACTOR]]
 +
Scale on which to look for edges. Positive LCESCALE switches on local contrast enhancement by LCEFACTOR (EDGESCALE, LCESCALE, LCEFACTOR >= 0).<br>
 +
Append "%" to LCESCALE for values relative to EDGESCALE; <br>
 +
append "%" to LCEFACTOR for relative value.  Defaults: 0:0:0
 +
 
 +
--MinCurvature=CURVATURE
 +
Minimum CURVATURE for an edge to qualify.  Append "%" for relative values.  Default: 0.
  
 
  --debug
 
  --debug
 
Output intermediate images for debugging.
 
Output intermediate images for debugging.
  
 +
== External Links ==
 +
=== Command line ===
 +
Another implementation of the enfuse algorithm is TuFuse from Max Lyons, which features automatic [[Depth_of_Field|DOF]] fusion (from a focus stack) and exposure fusion in one go as well as some additional options: http://www.tawbaware.com/tufuse.htm (freeware, windows only)
 +
 +
=== GUIs ===
 +
enfuse has triggered the development of some GUIs.
 +
 +
==== Multi platform ====
 +
 +
* The recent release of [[hugin]] has integrate enfuse fully. Get it from http://hugin.sourceforge.net (open source).
 +
 +
* [[PTGui]] Pro since version 7.7 has a built in image fusion tool which features the exposure criterion only but has extended adjustment possibilities.
 +
 +
* LR/Enfuse is a Lightroom plugin for blending exposures directly from within Lightroom using Enfuse.  It works on Mac and PC.  Get it from http://photographers-toolbox.com/products/lrenfuse.php
 +
 +
==== Linux ====
 +
 +
* [http://panorama.dyndns.org/index.php?lang=en&subject=KImageFuser&texttag=KImagefuser KImageFuser] by Harry van der Wolf is an enfuse/align_image_stack Gui for Linux (free GPL V3). It has a preview function and batch options. It is written in the graphical script environment [http://kommander.kdewebdev.org/ kommander] and can run on any linux platform. Dependencies are: kdewebdev-3.5.9 or newer, [http://enblend.sourceforge.net enfuse], align_image_stack (from [http://hugin.sourceforge.net Hugin]), convert ([http://www.imagemagick.org ImageMagick]). Not a dependendency but highly recommended: [http://www.sno.phy.queensu.ca/~phil/exiftool/ Exiftool] to be able to copy all relevant exif data (ImageDescription, Make, Model, Artist, WhitePoint, Copyright, GPS:all, DateTimeOriginal, CreateDate, UserComment, ColorSpace, OwnerName, SerialNumber, all IPTC, all JFIF, XResolution, YResolution, ResolutionUnit, Lens, FocalLengthIn35mmFormat and FocalLength) to the new image. All dependencies are available in the main linux distributions. Note also that at least one KDE theme should be available like e.g. the famous (and default) "bluecurve" theme. KImageFuser has also been added to the [https://hugin.svn.sourceforge.net/svnroot/hugin/ Hugin svn] in it's own project  [https://hugin.svn.sourceforge.net/svnroot/hugin/KImageFuser KImageFuser] tree.
 +
* [http://www.digikam.org/ digiKam] can use enfuse to blend bracketed images.
 +
 +
==== Windows ====
 +
* The droplets by Erik Krause are contained in the [[hugin]] windows package from http://hugin.sourceforge.net and installed ready to use. A group of image files or an entire folder can be dragged and dropped on a droplet. In case of a folder the user can specify the number of images in a bracketed series, hence multiple series can be enfused in one go. The droplets copy relevant EXIF data to the result image such that camera and lens data isn't lost f.e. for subsequent stitching. Another droplet version does automatic alignment in order to allow for handheld bracketed series. (open source)
 +
 +
* [http://software.bergmark.com/enfuseGUI/ EnfuseGUI] by Ingemar Bergmark is a graphical user interface (free).
 +
 +
*[http://www.tawbaware.com/tufusepro.htm TuFuse Pro] by Max Lyons is a nice graphical user interface to his own [http://www.tawbaware.com/tufuse.htm tufuse] free command line application (commercial)
 +
 +
* [http://www.tawbaware.com/forum2/viewtopic.php?t=4966 Tufusion] is a free GUI for Max Lyons' tufuse, developed by TuFuse forum user "entropy". It's not as sophisticated as TuFuse Pro, but it surely makes life a lot easier, compared to using the command line application.
 +
 +
==== Mac OSX ====
 +
 +
* [http://pangeasoft.net/pano/bracketeer/ Bracketeer] (commercial) by ''Brian Greenstone'' is a graphical user interface with preview function for OS X 10.4 and higher.
 +
 +
* [http://software.bergmark.com/enfuseGUI/ EnfuseGUI] (donationware) by ''Ingemar Bergmark'' is a graphical user interface for OS X 10.4 and higher.
 +
 +
* [http://panorama.dyndns.org/index.php?lang=en&subject=ImageFuser&texttag=ImageFuser ImageFuser] ([http://groups.google.com/group/hugin-ptx/browse_thread/thread/711ec6caf975785e Open Source]) by ''Harry van der Wolf'' is a graphical user interface for enfuse and [[align_image_stack]] with preview function for OS X 10.4 and higher.
 +
 +
* [http://www.kekus.com/legacy_products.html XFuse] (free) by ''Kevin Kratzke'' is a graphical user interface that allows for batch processing and works on OS X 10.4 and higher. Development of this application is discontinued, last downloadable version is 0.5 as of Feb. 8, 2008.
  
 
[[Category:Software:Platform:Mac OS X]]
 
[[Category:Software:Platform:Mac OS X]]
 
[[Category:Software:Platform:Linux]]
 
[[Category:Software:Platform:Linux]]
 
[[Category:Software:Platform:Windows]]
 
[[Category:Software:Platform:Windows]]

Revision as of 14:42, 18 December 2012

Enfuse is a command-line program used to merge different exposures of the same scene to produce an image that looks very much like a tonemapped image (without the halos) but requires no creation of an HDR image. Therefore it is much simpler to use and allows the creation of very large multiple exposure panoramas.

Enfuse is based on a paper by Tom Mertens, Jan Kautz and Frank Van Reeth: "Exposure fusion" The implementation was done by Andrew Mihal (developer of Enblend) and the hugin team around Pablo d'Angelo

An extended documentation could be found on Enfuse reference manual

Other programs using Exposure Fusion: tufuse and PTGui Pro

State of development

On 8 September 2008 the first official version of enfuse has been released together with enblend. Enfuse/enblend can be downloaded from enblend.sourceforge.net. On that site you will find the 3.2 version source code as well as precompiled windows binaries.

Beta (development) releases can be downloaded from

Known bugs

(This section needs to be updated)
This is a list of known bugs in the current version as linked above. For a list of bugs in previous versions please refer to an older version of this page

  • If contrasty structures are near zenith or nadir in an equirectangular image, there might be an artifact (vortex) in the resulting pano.
Workaround: use on zenith and nadir images separately and stitch them in the resulting pano afterwards.
- unknown, whether could be fixed easily

Description

Enfuse merges overlapping images using the Mertens-Kautz-Van Reeth exposure fusion algorithm. This is a quick way to blend differently exposed images into a nice output image, without producing intermediate HDR images that are then tonemapped to a viewable image. This simplified process often works much better than the currently known tonemapping algorithms.

Enfuse can also be used to build extended DOF images, by blending a focus stack.

Basics

The basic idea is that pixels in the input images are weighted according to qualities such as proper exposure, good contrast, and high saturation. These weights determine how much a given pixel will contribute to the final image.

This idea is not quite new. F.e. Ardeshir Goshtasby proposed a technique to select and blend only well exposed blocks and Erik Krause provided a photoshop action to smart mask badly exposed areas. Many such "DRI" or "Exposure Blending" solutions exist.

The problem of all this techniques was to find good transitions between the areas taken from differently exposed images. There always was a risk of getting banding or even reversed gradients within areas where the brightness gradually changed.

Enfuse solves this problem by using the multi resolution spline blending technique well known from enblend and smartblend - and it is actually this step which is responsible for the wonderful results. The technique is described detailed for enblend and it works almost the same for enfuse, with the exception that instead of the initial seam line a mask is created according to the given criteria.

Enfuse uses three different criteria to judge the quality of a pixel: Exposure, saturation, and contrast.

  • The exposure criteria favors pixels with luminance close to the middle of the range. These pixels are considered better-exposed than those with high or low luminance levels.
  • The saturation criteria favors highly-saturated pixels.
  • The contrast criteria favors high-contrast pixels. The local gray or color value standard deviation is used as a contrast measure. The Mertens-Kautz-Van Reeth paper suggest using a laplacian filter, but the standard deviation produces much better results for differently focused images.

Adjustments

You can adjust how much importance is given to each criteria by setting the weight parameters on the command line. For example, if you set --wExposure=1.0 and --wSaturation=0.5, Enfuse will favor well-exposed pixels over highly-saturated pixels when blending the source images. The impact of these parameters on the final result will not always be clear. The quality of the result is subject to your artistic interpretation. Playing with the weights may or may not give you a more pleasing result. I encourage you to experiment (perhaps using downsized images for speed).

Enfuse allows each input image to have an alpha channel. By setting the alpha values of pixels to zero, users can manually remove those pixels from consideration when blending. If an input image lacks an alpha channel, Enfuse will print a warning and continue assuming all pixels should be processed for final output. Any alpha value other than zero is interpreted as "this pixel should should be considered for the final image".

Usage

The usage below refers to the CVS version of the 21 Dec 2007. Use enfuse as follows:

enfuse <options> <input files>.

Input files can be a list of files or a wildcard (on windows f.e. IMG*.jpg for all jpg images that begin with IMG.

Common options

-h

Print information on the available options.

-l num

Use exactly this many levels for pyramid blending. A low number trades off quality of results for faster execution time and lower memory usage. The default is to use as many levels as possible given the source image size. However, recent versions don't seem to do that hence it might be useful to specify an arbitrary high number (f.e. -l 20) for best results. If you specify a high number Enfuse may still use a smaller number of levels if the geometry of the images demands it.

-o output-file

Required. Specify the name of the output file.

-v

Verbose output.

-w

Blend around the -180/+180 boundary. Useful for full-360 panoramas. Enfuse currently does not blend the zenith or the nadir, so you may still see some seams in these areas.

--compression=COMP

Write a compressed output file. Valid values are NONE, PACKBITS, LZW and DEFLATE for TIFF files, and numbers from 0-100 for JPEG files.

Extended options

-b kilobytes

Set the block size for Enfuse's image cache. This is the amount of data that Enfuse will move to and from the disk in one go. The default is 2 MiB which should be good for most systems.

-c

Use the CIECAM02 color appearance model for blending colors. Your input TIFF files should have embedded ICC profiles. If no ICC profile is present, Enfuse will assume that image uses the sRGB color space. The difference between using this option and Enfuse's default color blending algorithm is very slight, and will be most noticeable when you need to blend areas of different primary colors together.

-g

Gimp (ver. < 2) and Cinepaint exhibit unusual behaviors when loading images with unassociated alpha channels. Use the -g flag to work around this. With this flag Enfuse will create the output image with the associated alpha tag set, even though the image is really unassociated alpha.

-f WIDTHxHEIGHT+x0+y0

Set the size and position of the output image manually. This is useful when the input images are cropped TIFF files, such as those produced by Nona.

-m megabytes

Set the size of Enfuse's image cache. This is the amount of RAM (in megabytes) Enfuse will use for storing image data before swapping to disk. The default is 1024 MB.

Fusion options

W is a number between 0 (no weight) and 1 (full weight)

--wExposure=W

Sets the relative weight of the well-exposedness criterion. Increasing this weight relative to the others will make well-exposed pixels contribute more to the final output.

--wSaturation=W

Sets the relative weight of high-saturation pixels. Increasing this weight makes pixels with high saturation contribute more to the final output.

--wContrast=W

Sets the relative weight of high-contrast pixels. Increasing this weight makes pixels with neighboring differently colored pixels contribute more to the final output. Particularly useful for focus stacks.

--wMu=mu

Mean of the gaussian weighting function (from 0 to 1) for the exposure criterion only. default value: 0.5. This moves the peak of the curve towards the brighter or darker end of the histogram. Higher values pick more brighter pixels from the source images, lower values more darker ones.

--wSigma=sigma 

Standard deviation of the gaussian weighting function (from 0) for the exposure criterion only. default value: 0.2. Higher values cause a wider curve and more pixels to be taken from a particular image (possibly including under- and over-exposed ones). A lower value causes a narrower curve and less pixels to be taken, possibly resulting in banding.

--HardMask

Force hard blend masks on the finest scale. This avoids averaging of fine details (only), at the expense of increasing the noise. This improves the sharpness of focus stacks considerably.

Expert options

--ContrastWindowSize=s

Window size for local contrast analysis. Values larger than 5 might result in increased computation times. Values in the range of 3 to 7 have given good results on focus stacks. The impact on the result quality is not easy to define. You will have to experiment.

--GrayProjector=OPERATOR

Apply grayscale projection OPERATOR, where OPERATOR is one of "average", "l-star", "lightness", "value", "luminance", or "channel-mixer:RED-WEIGHT:GREEN-WEIGHT:BLUE-WEIGHT". Default: "average"

--EdgeScale=EDGESCALE[:LCESCALE[:LCEFACTOR]]

Scale on which to look for edges. Positive LCESCALE switches on local contrast enhancement by LCEFACTOR (EDGESCALE, LCESCALE, LCEFACTOR >= 0).
Append "%" to LCESCALE for values relative to EDGESCALE;
append "%" to LCEFACTOR for relative value. Defaults: 0:0:0

--MinCurvature=CURVATURE

Minimum CURVATURE for an edge to qualify. Append "%" for relative values. Default: 0.

--debug

Output intermediate images for debugging.

External Links

Command line

Another implementation of the enfuse algorithm is TuFuse from Max Lyons, which features automatic DOF fusion (from a focus stack) and exposure fusion in one go as well as some additional options: http://www.tawbaware.com/tufuse.htm (freeware, windows only)

GUIs

enfuse has triggered the development of some GUIs.

Multi platform

  • PTGui Pro since version 7.7 has a built in image fusion tool which features the exposure criterion only but has extended adjustment possibilities.

Linux

  • KImageFuser by Harry van der Wolf is an enfuse/align_image_stack Gui for Linux (free GPL V3). It has a preview function and batch options. It is written in the graphical script environment kommander and can run on any linux platform. Dependencies are: kdewebdev-3.5.9 or newer, enfuse, align_image_stack (from Hugin), convert (ImageMagick). Not a dependendency but highly recommended: Exiftool to be able to copy all relevant exif data (ImageDescription, Make, Model, Artist, WhitePoint, Copyright, GPS:all, DateTimeOriginal, CreateDate, UserComment, ColorSpace, OwnerName, SerialNumber, all IPTC, all JFIF, XResolution, YResolution, ResolutionUnit, Lens, FocalLengthIn35mmFormat and FocalLength) to the new image. All dependencies are available in the main linux distributions. Note also that at least one KDE theme should be available like e.g. the famous (and default) "bluecurve" theme. KImageFuser has also been added to the Hugin svn in it's own project KImageFuser tree.
  • digiKam can use enfuse to blend bracketed images.

Windows

  • The droplets by Erik Krause are contained in the hugin windows package from http://hugin.sourceforge.net and installed ready to use. A group of image files or an entire folder can be dragged and dropped on a droplet. In case of a folder the user can specify the number of images in a bracketed series, hence multiple series can be enfused in one go. The droplets copy relevant EXIF data to the result image such that camera and lens data isn't lost f.e. for subsequent stitching. Another droplet version does automatic alignment in order to allow for handheld bracketed series. (open source)
  • EnfuseGUI by Ingemar Bergmark is a graphical user interface (free).
  • TuFuse Pro by Max Lyons is a nice graphical user interface to his own tufuse free command line application (commercial)
  • Tufusion is a free GUI for Max Lyons' tufuse, developed by TuFuse forum user "entropy". It's not as sophisticated as TuFuse Pro, but it surely makes life a lot easier, compared to using the command line application.

Mac OSX

  • Bracketeer (commercial) by Brian Greenstone is a graphical user interface with preview function for OS X 10.4 and higher.
  • EnfuseGUI (donationware) by Ingemar Bergmark is a graphical user interface for OS X 10.4 and higher.
  • XFuse (free) by Kevin Kratzke is a graphical user interface that allows for batch processing and works on OS X 10.4 and higher. Development of this application is discontinued, last downloadable version is 0.5 as of Feb. 8, 2008.