[libcamera-devel,v5,00/10] ipa: rkisp1: Add autofocus algorithm
mbox series

Message ID 20230324142908.64224-1-dse@thaumatec.com
Headers show
Series
  • ipa: rkisp1: Add autofocus algorithm
Related show

Message

Daniel Semkowicz March 24, 2023, 2:28 p.m. UTC
This is the updated version of the common contrast based Auto Focus
algorithm implementation and it's usage for RkISP1 AF implementation.

Main changes in v5:
- Improve documentation
- Fix language errors in the documentation
- Remove default branches in some of the switch cases
- Remove unused fineCompleted_ and previousContrast_ variables
  in AfHillClimbing
- Fix incorrect multiline comments indention
- Add "to do" lists to the AfHillClimbing and rkisp1::Af
- Add static_cast in additional places pointed by clang-tidy
- Change "fine-search-range" tuning parameter to be expressed
  in percents
- Connect setLensControls() slot in PH, only if lens is available
- Rework setLensControls() to iterate through the control list, instead
  of calling contains() and get().

Daniel Semkowicz (10):
  rkisp1: Add camera lens to PH and expose it to the IPA
  ipa: rkisp1: Add lens limits to the session config
  ipa: Add base class defining AF algorithm interface
  ipa: Add common contrast based AF implementation
  ipa: af_hill_climbing: Add "Windows" metering mode
  ipa: rkisp1: Add AF algorithm based on AfHillClimbing
  ipa: rkisp1: af: Add "Windows" Metering mode
  ipa: rkisp1: Add AF controls to the RkISP1 IPA
  rkisp1: Control camera lens position from IPA
  ipa: rkisp1: Add OV5675 tuning file

 include/libcamera/ipa/rkisp1.mojom            |   2 +
 src/ipa/libipa/algorithms/af.cpp              | 159 +++++++
 src/ipa/libipa/algorithms/af.h                |  45 ++
 .../libipa/algorithms/af_hill_climbing.cpp    | 418 ++++++++++++++++++
 src/ipa/libipa/algorithms/af_hill_climbing.h  | 101 +++++
 src/ipa/libipa/algorithms/meson.build         |  11 +
 src/ipa/libipa/meson.build                    |   6 +
 src/ipa/rkisp1/algorithms/af.cpp              | 179 ++++++++
 src/ipa/rkisp1/algorithms/af.h                |  54 +++
 src/ipa/rkisp1/algorithms/meson.build         |   1 +
 src/ipa/rkisp1/data/meson.build               |   1 +
 src/ipa/rkisp1/data/ov5675.yaml               |  18 +
 src/ipa/rkisp1/ipa_context.cpp                |  25 ++
 src/ipa/rkisp1/ipa_context.h                  |  10 +
 src/ipa/rkisp1/rkisp1.cpp                     |  30 ++
 src/libcamera/pipeline/rkisp1/rkisp1.cpp      |  18 +
 16 files changed, 1078 insertions(+)
 create mode 100644 src/ipa/libipa/algorithms/af.cpp
 create mode 100644 src/ipa/libipa/algorithms/af.h
 create mode 100644 src/ipa/libipa/algorithms/af_hill_climbing.cpp
 create mode 100644 src/ipa/libipa/algorithms/af_hill_climbing.h
 create mode 100644 src/ipa/libipa/algorithms/meson.build
 create mode 100644 src/ipa/rkisp1/algorithms/af.cpp
 create mode 100644 src/ipa/rkisp1/algorithms/af.h
 create mode 100644 src/ipa/rkisp1/data/ov5675.yaml