I was just playing around with some settings in darktable (5.0, Linux Mint Cinnamon 22), and I noticed some strange behaviour, when using the $(WIDTH.x) and $(HEIGHT.x) variables, defining the extended overlays and thumbnail tooltips in lighttable
The $(x.RAW) and $(x.SENSOR) variables always show equal pixel values, regardless of the camera (I checked raw files from >10 cameras from Nikon, Canon and Pentax). Usually there is a (usually small) difference between raw image size and sensor size. What exactly is darktable showing here?
The $(WIDTH.x) and $(HEIGHT.x) always show the long and short sides, respectively, regardless of the image orientation (landscape or portrait). Example: for a 6000Ă—4000 pixel (raw) image $(WIDTH.x) always shows 6000 and $(HEIGHT.x) 4000 pixel, regardless of the image orientation (for portrait orientation $(WIDTH.x) should be 4000, and $(HEIGHT.x) 6000). Or is this, for some reason, done on purpose?
The $(x.CROP) and $(x.EXPORT) variables always show 0 width and 0 height. As far as I understand, the $(x.CROP) variables should show the image size as defined by the “crop” and “rotate and perspective” (and possibly some other) modules. As for the $(x.EXPORT) variables, it is not clear to me, what should be shown here: current settings of the export module, or perhaps the last exported size of the image, or maybe some other value?
These are of course not vital problems, but it would be nice to know what these variables are actually showing …
You’ll probably want to read the source code if you want to know exactly what is going on. Here is the documentation: darktable 4.6 user manual - variables
Thank you for your answer!
Yes, I read the manual, but from the information therein I could not find the answers to my questions.
As for the source code, this will probably not help me much - I’m not a software engineer
For me the especially confusing are $(x.CROP) and $(x.EXPORT) variables, that are always showing 0 (zero) pixels - maybe I’m doing something wrong, but the result is not what I can get out of the manual …
Maybe not answering your question, but I want to know how many pixels I have left after cropping has occurred so I have this shown as part of the information under my images in the darkroom view. To get this in the preferences I have set WIDTH.CROP and HEIGHT.CROP. If the image isn’t cropped then it shows all the pixels available for that camera. I hope this helps you.
Thank you for your answer!
I’m doing the same as you, but that is actually the problem in my case: $(WIDTH.CROP)×$(HEIGHT.CROP) results in correct (cropped image size) indication when in darkroom and in 0×0 indication when in lighttable (overlays and/or pop-ups), as shown below
As I understand these values are managed by rawspeed, the raw decoder darktable uses for most image formats. The size related informations seem to be saved (partly) in different tags by different manufacturers.
So I suspect that rawspeed is not able to correctly determine the desired values from the metadata in your cases. But as already said : one would have to look into the source code (probably also from rawspeed) to understand what is really the cause.
Thank you for the idea to clear .config!
I did as you suggested, but no success - the behaviour is still the same as before:
$(WIDTH.CROP) and $(HEIGHT.CROP) give values 0 in lighttable and correct values in darkroom …