#!/bin/bash # create a temporary file for a default processing profile # here, we want to make sure we have a suitably large output color space, # because we want to continue editing after stitching t=$(mktemp --suffix=.arp) cat < $t [Version] Version=1015 [Color Management] OutputProfile=RTv4_ACES-AP1 EOF if [ -f "$1.arp" ]; then # if the first selected file has a sidecar, we are going to use that # (except that we override the output profile, see above) sidecar=("-p" "$1.arp") else # if the first selected file has no sidecar, we create a default one sidecar=() cat <> $t [Exposure] HLRecovery=Blend [ToneCurve] Enabled=false [LensProfile] LcMode=lfauto LCPFile= UseDistortion=true UseVignette=true UseCA=false [RAW] CAEnabled=true CA=true CAAvoidColourshift=true CAAutoIterations=2 EOF fi # process the raw files with ART-cli, adding a progress dialog # for user notification ART-cli "${sidecar[@]}" -p $t -Y -t -b16 -c "$@" | zenity --progress --pulsate --no-cancel --auto-close --text="Converting to TIFF..." # remove the temporary sidecar rm -f $t # prepare the list of arguments to provide to hugin. # Note: we are using bash arrays here to be robust wrt. file names # with spaces and/or other funny characters i=0 for fn in "$@"; do tiffs[$i]="${fn%.*}.tif" i=$(expr $i + 1) done editor_names="Gimp Krita Luminance_hdr Analog_Efex_Pro2 Silver_Efex_Pro2 Color_Efex_Pro4 Dfine2 HDR_Efex_Pro2 Sharpener_pre_raw Sharpener_out QTR-Piezzo " # EDITME - list of editors i=0 args="" for e in $editor_names; do i=$(expr $i + 1) args="$args $i $e" done selected=$(zenity --list --column="ID" --column="Name" --title="Select the Editor" --height=400 --hide-column=1 --print-column=1 $args) if [ "$selected" = "1" ]; then /usr/bin/gimp-2.10 "${tiffs[@]}" # EDITME - command line for GIMP elif [ "$selected" = "2" ]; then krita "${tiffs[@]}" # EDITME - krita elif [ "$selected" = "3" ]; then /usr/bin/luminance-hdr "${tiffs[@]}" # EDITME - command line for luminance-hdr elif [ "$selected" = "4" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Analog Efex Pro 2/Analog Efex Pro 2 (64-Bit)/Analog Efex Pro 2.exe' "${tiffs[@]}" # EDITME - Analog Efex pro elif [ "$selected" = "5" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Silver Efex Pro 2/Silver Efex Pro 2 (64-Bit)/Silver Efex Pro 2.exe' "${tiffs[@]}" # EDITME - Silver Efex pro elif [ "$selected" = "6" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Color Efex Pro 4/Color Efex Pro 4 (64-Bit)/Color Efex Pro 4.exe' "${tiffs[@]}" # EDITME - Color Efex pro elif [ "$selected" = "7" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Dfine 2/Dfine 2 (64-Bit)/Dfine2.exe' "${tiffs[@]}" # EDITME - Dfine exit 0 elif [ "$selected" = "8" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Viveza 2/Viveza 2 (64-Bit)/Viveza 2.exe' "${tiffs[@]}" # EDITME - Viveza elif [ "$selected" = "9" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Sharpener Pro 3/Sharpener Pro 3 (64-Bit)/SHP3RPS.exe' "${tiffs[@]}" # EDITME - Sharpener pre raw elif [ "$selected" = "10" ]; then '/home/jllailes/.PlayOnLinux/wineprefix/default/drive_c/Program Files/Google/Nik Collection/Sharpener Pro 3/Sharpener Pro 3 (64-Bit)/SHP3OS.exe' "${tiffs[@]}" # EDITME - Sharpener out elif [ "$selected" = "11" ]; then '/home/jllailes/.wine/drive_c/Program Files (x86)/QuadToneRIP/bin/QTRgui.exe' "${tiffs[@]}" # EDITME - QTR-Piezzo exit 0 fi #!/bin/bash