Page 1 of 1

unable to read/convert NEF

Posted: 2012-09-18T07:28:43-07:00
by allen0stewart
I'm trying to inspect and convert NEF files on Mac OS X (10.7 or 10.8) using imagemagick builds from brew and the latest code that I built myself. Both yield the same error:

mini$ identify ordered/2011-04-29/11_DSC_0072.NEF
identify: delegate failed `"ufraw-batch" --silent --create-id=also --out-type=png --out-depth=16 "--output=%u.png" "%i"' @ error/delegate.c/InvokeDelegate/1065.
identify: unable to open image `/var/folders/r0/cq70ddl15dncl6txwl63dpj40000gn/T/magick-4W18Mduz.ppm': No such file or directory @ error/blob.c/OpenBlob/2617.

or converting

mini$ convert -verbose ordered/2011-04-29/11_DSC_0072.NEF foo.jpg
"ufraw-batch" --silent --create-id=also --out-type=png --out-depth=16 "--output=/var/folders/r0/cq70ddl15dncl6txwl63dpj40000gn/T/magick-I3MJLyH0.png" "/var/folders/r0/cq70ddl15dncl6txwl63dpj40000gn/T/magick-qug0V3Z0"
convert: delegate failed `"ufraw-batch" --silent --create-id=also --out-type=png --out-depth=16 "--output=%u.png" "%i"' @ error/delegate.c/InvokeDelegate/1065.
convert: unable to open image `/var/folders/r0/cq70ddl15dncl6txwl63dpj40000gn/T/magick-I3MJLyH0.ppm': No such file or directory @ error/blob.c/OpenBlob/2617.
convert: no images defined `foo.jpg' @ error/convert.c/ConvertImageCommand/3032.

identifying and converting other image types works

Re: unable to read/convert NEF

Posted: 2012-09-18T07:57:46-07:00
by magick
On the Mac, you must either install ufraw-batch or dcraw to read NEF image files. If you use dcraw, you must edit delegates.xml and use something similar to:
  • <delegate decode="dng:decode" stealth="True" command="dcraw.exe -6 -w -O "%u.ppm" "%i""/>

Re: unable to read/convert NEF

Posted: 2012-09-18T09:46:17-07:00
by allen0stewart
thanks, that's it!! now I just have to convince ufraw to build with PNG support on mac... neither the brew version nor compiling from source wants to do this :(

Re: unable to read/convert NEF

Posted: 2012-09-18T10:16:50-07:00
by allen0stewart
solution:

brew edit ufraw

add the line:
depends_on 'libpng'

brew uninstall ufraw
brew install ufraw

Re: unable to read/convert NEF

Posted: 2012-11-15T07:34:17-07:00
by kalagani
Hello,
I don't understand wich post meet the solution:
1) from magick:
edit delegates.xml
is the /etc/ImageMagick/delegates.xml?
Is this file for ufraw-batch or for dcraw?

2) or from allenOstewart:
is brew a special editor to edit the binary ufraw file?
or do you say about ufraw-batch file?
Thanks

PS:
I have similar pb (convert NEF to JPG) but only with NEF from a coolscan LS50 scanner (no pb with NEF from D200 camera)

Code: Select all

convert Image1.nef Image1.jpg
convert: Échec de la délégation `"ufraw-batch" --silent --create-id=also --out-type=png --out-depth=16 "--output=%u.png" "%i"' @ error/delegate.c/InvokeDelegate/1049.
convert: impossible d'ouvrir l'image `/tmp/magick-B1eHdUjj.ppm': Aucun fichier ou dossier de ce type @ error/blob.c/OpenBlob/2614.
convert: nom de fichier d'image absent `Image1.jpg' @ error/convert.c/ConvertImageCommand/3017.
I am using

Code: Select all

imagemagick-6.7.5.10-2.1.mga2 ufraw-0.18-3.mga2 dcraw-9.12-1.mga2
all under Linux on PC