Basecurves

Let’s build our own basecurves

In this episode I work through each of the steps needed to build a custom basecurve. I also share some code I use to build a separate base curve for each camera body and ISO I use. In the end I show how to set up Darktable to automatically apply the appropriate basecurve to your RAW files.

Another in our faster format, but packed with information. It builds on knowledge from previous videos, running full-tilt through tools and methods to achieve the edit. For fuller explanations, return to the Home Page and scroll down to Topics Discussed or Modules Used on the right-hand bar. Click on any of these, and we assemble a complete playlist of every instance from a knowledge base of our first 27 videos for quick review right here on the site.

Build dt-curve-tool

cd
cp .config/darktable/data.db .config/darktable/data.db.bak
git clone git://github.com/darktable-org/darktable.git
cd darktable/tools/basecurve
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=$YOUR_INSTALL_PATH -DCMAKE_BUILD_TYPE=Release ..
sudo cmake --build . -- install

sample.jpg for creating basecurve

My script to build basecurves (make sure Darktable isn’t running when you run this)

#!/bin/zsh
rm iso_model_* basecurve.dat basecurve.fit.dat basecurve.sh dt-curve-tool.bin tonecurve.dat tonecurve.fit.dat
ls |grep -i jpg |head -n1 |cut -d'.' -f1 |read file
ls "$file".* |grep -iv jpg |grep -iv xmp |head -n1 |cut -d'.' -f2 |read ext
ls *.$ext |while read file; do
  exiftool "$file" |grep -i iso |head -n1 |awk -F': ' '{print $2}' |read iso
  exiftool "$file" |grep -i model |head -n1 |awk -F': ' '{print $2}' |read model
  echo $file $iso $model >>iso_model_db
done
cat iso_model_db |cut -d' ' -f2- |sort |uniq >iso_model_combinations
cat iso_model_combinations |while read combo; do
  echo $combo |cut -d' ' -f1 |read iso
  echo $combo |cut -d' ' -f2- |read model
  grep " $combo" iso_model_db |cut -d' ' -f1 |while read file; do
    dt-curve-tool-helper "$file"
    last="$file"
  done
  dt-curve-tool -z -e $last -n6 |sed -e "s/$model/$model ($iso)/g" >basecurve.sh
  sh ./basecurve.sh
  rm basecurve.dat basecurve.fit.dat basecurve.sh dt-curve-tool.bin tonecurve.dat tonecurve.fit.dat
done
tiny planet view of Kahakai Park, Hawaii composed by Harry Durgin in opensource tools Hugin, GIMP, Darktable for his Weekly Edit tutorial

Tiny Planet

Just for fun

In this episode I start with a 360 panorama and make a tiny planet picture. I share some tips on setting up the shot. Then I do some pre-processing in Darktable, assembly in Hugin, conversion to radial in the GIMP, and some final touches back in Darktable.
It's a tiny-planet tour of opensource tools to compose a tiny planet of my local morning.
This video is the latest in our faster-edit format. It builds on knowledge from previous videos, running full-tilt through tools and methods to achieve the edit. For fuller explanations, return to the Home Page and scroll down to Topics Discussed or Modules Used on the right-hand bar. Click on any of these, and we assemble a complete playlist of every instance from a knowledge base of our first 27 videos for quick review right here on the site.

Holger’s Darktable Plugin for Enfuse

Time saving Darktable plugin for HDR and focus stacking

In this episode I take a first look at Holger's lua plugin for stacking. I walk through downloading and installing the lua script to provide a front-end for align_image_stack and enfuse. There are a couple bits along the way that this will smooth over for you.
We then take a quick look at how this works with an image.
Thank you Holger! You've made all our lives easier and our edits more fun.
I've translated Holger's README file into English for you below.

enfuse_pro-2.1beta1.tar @multimedia4linux.de
enfuse_pro-2.1beta1.tar @weeklyedit.com

Sunrise RAW 6 sec
Sunrise RAW 30 sec

Holger’s README in english

Installation on Ubuntu:

1.) First the Lua script language must be installed with the following commands:

sudo apt-get update
sudo apt-get install liblua5.2-0 liblua5.2-dev lua5.2 lua5.2-doc

2.) The program align_image_stack (contained in hugin-tools), enfuse and exiftool is needed for the generation of the HDR and DFF (Focus Stacking) images. Install it with:

sudo apt-get install hugin-tools enfuse libimage-exiftool-perl

(added by Harry) You may also require upgrading your enfuse to 4.2

sudo add-apt-repository ppa:hugin/hugin-builds
sudo apt-get update
sudo apt-get upgrade

3.) If not already present, create the following directories:

~/.config/darktable/lua/contrib
~/.config/darktable/lua/en_DE/LC_MESSAGES

4.) Copy the Lua script enfuse_pro.lua

~/.config/darktable/lua/contrib

5.) To start the script the luarc file has to be created or edited. The text file ~/.config/darktable/luarc has to be opened or created with a text editor.
Add the following to the luarc file:

require "contrib/enfuse_pro"

After a reboot of darktable the plugin under the name "fusion to hdr or dff image" should appear in the target storage options of the export function.

In the global presets under the tab Lua Options there are further settings for the plug-in.

PS: The script only works when you start Darktable normally from the menu or from the terminal window when you are in your home directory. If you are not in the home directory, align_image_stack saves the images to an incorrect location and enfuse will not find you!

Have fun
Holger