thumbnails
Each image in the current collection is represented by a thumbnail in the lighttable view and filmstrip module. A cache of the most recently used thumbnails is stored in a file on disk and loaded into memory at startup.
🔗thumbnail creation
A thumbnail is created when an image is imported into darktable for the first time, after an image has been modified in the darkroom, or when revisiting an image whose thumbnail is no longer available.
When an image is imported for the first time darktable can either try to extract an embedded thumbnail from the input image (most raw files contain these, usually in JPEG format) or process the raw image itself using default settings. You can define how darktable obtains its thumbnails in preferences > lighttable > thumbnails.
Extracting an embedded thumbnail from the input image is usually very fast. However, these thumbnails have been generated by the raw converter of the camera and do not represent darktable’s “view” of that image. You will notice the difference as soon as you open the image in the darkroom mode, at which point darktable replaces the thumbnail with its own internally processed version.
After import darktable automatically generates thumbnails for new images as they are needed. When importing a large set of new images, thumbnail generation can slow down navigation in the lighttable view. Alternatively you may terminate darktable and generate the thumbnail cache separately by running darktable-generate-cache
. This program will generate all missing thumbnails in one go.
As the thumbnail cache has a pre-defined maximum size it will eventually get filled up. If new thumbnails are subsequently added, old thumbnails are dropped from the cache. However, darktable will keep all thumbnails on disk if the corresponding disk backend option is activated in preferences > lighttable > thumbnails. Access to the thumbnails in this secondary cache is slower than the primary cache, but still much faster than reprocessing thumbnails from scratch. The size of the secondary cache is limited only by the available disk space.
Thumbnails are never removed from the secondary cache. You can manually clean the secondary cache by recursively deleting all images in the $HOME/.cache/darktable/mipmaps-xyz.d
folder (where xyz
denotes an alphanumeric identifier of the cache). After clearing the secondary cache you can simply allow darktable to re-generate thumbnails as needed, or you can generate all thumbnails in one go with darktable-generate-cache
.
If you choose not to activate the disk backend and select too small a cache size, darktable may become unresponsive, you may experience continuous regeneration of thumbnails when you navigate your collection or flickering of thumbnail images. A good choice of cache size is 512MB or higher (see memory & performance tuning for more information).
All thumbnails are fully color managed. Colors are rendered accurately on screen as long as your system is properly set up to hand over the right monitor profile to darktable. For more information see the color management section.
🔗skulls, question marks, and warning triangles
If for some reason darktable is unable to generate a thumbnail, it displays one of three placeholder images to indicate the type of error preventing it from doing so.
There are three main reasons this could happen:
-
Missing image file: If the file could not be found at the location recorded in the database, a skull will be displayed in place of the image. You are advised to remove images from the database using the actions on selection module before physically removing them from disk. Alternatively you may occasionally run the purge script from darktable’s toolset to clean-up your database.
-
Invalid image format: While darktable will attempt to import all supported file extensions, the extension is not a guarantee that darktable will be able to interpret the file’s contents. If the file format (or an option within that format, such as compressed mode) is unsupported, darktable will display a question mark in place of the image. If the file appears to be corrupted, darktable will display a warning triangle in place of the image.
-
Low memory: In the rare event that darktable runs out of memory while generating a thumbnail, it will warn you and display a skull. This can happen if darktable is run with sub-optimal settings, especially on a 32-bit system. See memory & performance tuning for more information.