Under review

RAW/NEF thumbnails using vips very small...

operator 1 year ago updated by Vlad R 1 year ago 8

I installed libvips and libvips-tools in the docker container using apt-get which installed libvips42

Enabled vips thumbnail generation in filerun admin. Verified that the binary was installed...

Ran command: "vipsthumbnail" --vips-version
libvips 8.7.4-Sat Nov 21 16:50:57 UTC 2020

Now when I generate thumbnails from RAW images using vips  (Nikon NEF-format) the image in FileRun is 160x120.

Thumbnails are fine when browsing, but when I select a photo I get the very small thumbnail. 

How do I get bigger a preview in FileRun from RAW/NEF - JPEG's from same camera are displayed at 4512x3000

Image 857

Under review

I see in the "Image properties" that the XMP sidecar says the image is actually small.

Yes, I believe we are looking at the preview image created by the Nikon DSLR camera, it is embedded in the NEF file.

The 'real' image is 4012 x 6080

Here is a link to the 20MB NEF file above if you want to take a look...


Vips doesn't process RAW files, so this defaults to ImageMagick. You can confirm by using the file's control panel troubleshooting options to see what happens when a preview for that file is requested.

PHP/Exif is what reports the size of the file and that is not take into account when generating the preview.

Uploading this file in our demo shows proper size though, so you might want to look into updating ImageMagick maybe.

Thank you,  bastard Nikon saves the raw image as TIFF in the NEF-format so vips (through magickload) gets a little confused, I would guess...

I can add a workaround for it, but I will need some time, having very busy days atm.

I've been testing some more to understand where the insanely fast vips gets confused.

It would be great to have lightweight preview of the RAW/NEF files in FileRun,  they are 20MB files..

With vips enabled and imagemagick "convert" disabled in admin interface thumbnails are created  in two sizes 400x400 and 1860x750, but the images created are actually 160x120

The image is 6080x4012, the NEF contains four images - we're getting the first TIFF @ 160x120

$ exiv2 -p p mediaraid/photos/april2021/DSC_4497.NEF
Preview 1: image/tiff, 160x120 pixels, 57852 bytes
Preview 2: image/jpeg, 570x375 pixels, 96014 bytes
Preview 3: image/jpeg, 1632x1080 pixels, 824808 bytes
Preview 4: image/jpeg, 6016x4000 pixels, 1789541 bytes

Viewing the NEF file FileRun says the image is 160x120, not incorrect but it's the first preview of  the four.

Would be insanely great if this could be fixed.


Even better if FileRun would just extract the embedded preview of the most appropriate size when available. Will look into this and your details are very helpful.