I do photogrammetry with Nikon cameras. However, I've noticed that when I save my photos in grayscale in JPG format, I get images with three channels and slightly different values on each JPG with 3 channels. So, I've decided to save my photos in RAW format (NEF for Nikon).
I'm looking for software, on Windows, that I could use in command line and that would allow me to read my 14-bit NEF images and convert them to grayscale in 8-bit TIF format.
I found a function with ufraw that does exactly what I want but it's very slow (7 seconds for a 24Mpx image):
ufraw-batch.exe "XXX.NEF" --grayscale=mixer --grayscale-mixer=0.299,0.587,0.114 --out-type=tif --out-depth=8 --output="XXX.tif"
I tried with ImageMagick : magick.exe "XXX.NEF" -colorspace gray -depth 8 "XXX.tif"
However, I get overexposed images (white saturates at 255), I feel like it apply a bad color parameter but I can't apply custom parameters.
Finally, I tried with darktable-cli but I can't convert to grayscale.
Do you have any ideas or tips?