Last active
December 20, 2017 00:15
-
-
Save dbcesar/ff408076ae8ef503b04b4de73872fb8e to your computer and use it in GitHub Desktop.
For canon cameras. Move to a different folder all bracket images (useful for HDR creation)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
INPUT_DIR="$@" | |
if [ "$#" -ne 1 ]; then | |
echo "Wrong usage" | |
echo "Usage: move_bracket_shots_and_generate_tiff.sh <INPUT_DIR>" | |
exit | |
fi | |
if [ ! -d $INPUT_DIR ]; then | |
echo "The argument must be an directory" | |
exit | |
fi | |
OUTPUT_DIR="$INPUT_DIR/HDR" | |
mkdir -p $OUTPUT_DIR | |
exiftool "-directory=$OUTPUT_DIR" -if '$BracketMode eq "AEB"' $INPUT_DIR/* | |
echo "Converting $(ls -l $OUTPUT_DIR/*.CR2 | wc -l) images" | |
ufraw-batch $OUTPUT_DIR/*.CR2 --out-depth=16 --out-type=tif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment