Bug 512809 - Support for displaying focus points of Pentax K-1 / K-1 Mark II cameras
Summary: Support for displaying focus points of Pentax K-1 / K-1 Mark II cameras
Status: REPORTED
Alias: None
Product: digikam
Classification: Applications
Component: Metadata-Focus (other bugs)
Version First Reported In: 8.8.0
Platform: Other Linux
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-11-30 18:59 UTC by Milan Zamazal
Modified: 2025-11-30 20:46 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Milan Zamazal 2025-11-30 18:59:40 UTC
It would be nice to be able to display the focus points in photos from Pentax K-1 / K-1 Mark II cameras. Here are some samples of images from Pentax K-1 Mark II (Pentax K-1 has the same focus points) with AF points in EXIF:

http://data.zamazal.org/digikam/_K1_6900.JPG
http://data.zamazal.org/digikam/_K1_6901.JPG
http://data.zamazal.org/digikam/_K1_6902.JPG
http://data.zamazal.org/digikam/_K1_6903.JPG
http://data.zamazal.org/digikam/_K1_6904.JPG

The red objects in http://data.zamazal.org/digikam/_K1_6900.JPG are at the approximate locations of all the available K-1 focus points within the image.
Comment 1 Maik Qualmann 2025-11-30 19:36:17 UTC
Oh, es wird schwierig sein, zu verstehen, wie Pentax das handhabt.

Oh, this will be difficult to understand how Pentax handles it.

I'm not clear on what you photographed; it seems to be a screen with the focus points. Did you draw the focus points?

Pentax only uses a numbering system from 1 to about 33, no coordinates, and we don't know how they number them.

The reference implementation shows that a distinction must also be made between phase and contrast focus.

https://github.com/musselwhizzle/Focus-Points/blob/master/focuspoints.lrplugin/PentaxDelegates.lua

Maik
Comment 2 Milan Zamazal 2025-11-30 20:46:46 UTC
(In reply to Maik Qualmann from comment #1)
> Oh, this will be difficult to understand how Pentax handles it.

I don't think it's that difficult.

> I'm not clear on what you photographed; it seems to be a screen with the
> focus points. Did you draw the focus points?

It's a computer screen. I put the camera on a tripod, displayed the focus points in the viewfinder, and drew their positions on the screen while looking through the viewfinder. It's inaccurate but I suppose the pattern is more or less regular, so it should be possible to extract
some reasonable coordinates from it.

> Pentax only uses a numbering system from 1 to about 33, no coordinates, and
> we don't know how they number them.

They are numbered 1-33 from top left to right and then down. That is:

  1 2 3  4  5
 6 7 8 9 10 11 12
13 14 15 16 17 18 19 20 21
 22 23 24 25 26 27 28
  29 30 31 32 33

> The reference implementation shows that a distinction must also be made
> between phase and contrast focus.

Yes. The examples above are for phase focus.

The contrast detection pattern consists of a grid of 7x5 rectangles that covers most, but not whole, of the image area. Here are some examples:

http://data.zamazal.org/digikam/_K1_6906.JPG ... the central rectangle selected as the focus area and in focus
http://data.zamazal.org/digikam/_K1_6907.JPG ... the top left rectangle selected as the focus area and in focus
http://data.zamazal.org/digikam/_K1_6909.JPG ... the bottom right rectangle selected as the focus area and in focus
http://data.zamazal.org/digikam/_K1_6908.JPG ... the whole focusable area selected and the 2nd and 3rd rectangles from left in the first (top) row and from the second row are in focus

I can see some focus area coordinates in exiftool output but not the points in focus. They must be stored somewhere, the camera reports them.