Implementation of enfuse
It would be great if enfuse would be implemented as an alternative to the HDR function which is also great. Unfortunately, HDR merging can sometimes create weird artifacts, halos or strange ghosting where enfuse seems to blend in a more of an "average" style without creating these type of artifacts. Also the results can be sometimes superior to those of HDR merging. I understand that enfuse can be quite time consuming to run, especially if enfusing many shots. The advantage of enfuse is that even normal 8 bit (jpeg) images can be processed and then outputted to 16 or even 32 bit tiffs or EXRs with loads of headroom to edit. I sometimes like to do long exposure simulations with over 50 shots with enfuse and the results are quite great. Just wanted to know if it could be implemented sometime in DT to make workflow easier...
#2 Updated by Joe Giampaoli about 4 years ago
Thanks for your help!
Well I usually do in terminal in the directory where I have my shots (let's suppose they are JPG's):
enfuse -d n -o /my/output/file.tiff *.JPG
where n is either 16 or 32 bit depth
In rare cases I use the option:
for maybe startrails (I know starstax is much better with lighten mode)
How would I do that with Lua? I should start experimenting with Lua since CHDK also uses it...
#3 Updated by Tobias Ellinghaus about 4 years ago
Please test the attached script. It's not perfect yet but might be a good start for further refinements. If it works okay we will probably add it to our Lua script repo.
#5 Updated by Joe Giampaoli about 4 years ago
Just to let you know I finally had the opportunity to play a bit with the script. Works like a charm! I'll see if further edits or tweaks are needed but just being able to select the bit-depth and exposure-mu and being able to select which images to enfuse "visually" is a big plus!
Really appreciate it (again)
#6 Updated by Tobias Jakobs about 4 years ago
I looked at the script and to improve the temp file handling
-- create a temp response file
-- TODO: make filename unique
local response_file = dt.configuration.tmp_dir.."/enfuse_files.txt"
you may be interested in io.tmpfile () or os.tmpname ().
And to check if enblend is installed you may be interested in the checkIfBinExists() funktion I wrote in the hugin.lua script:
#7 Updated by Tobias Ellinghaus almost 4 years ago
- % Done changed from 50 to 100
- Status changed from In Progress to Fixed
Thanks for the pointers, I did some small changes and pushed the result to our script repo. One big TODO is that it still has the output filename "
enfuse.tiff" hardcoded. Using
tmpname() wouldn't work there. If anyone has a good idea we can fix that together.