[libcamera-devel,RFC,v3,0/1] ipa: ipu3: af: Auto focus for dw9719 Surface Go2 VCM
mbox series

Message ID 20211203120624.36657-1-hpa@redhat.com
Headers show
Series
  • ipa: ipu3: af: Auto focus for dw9719 Surface Go2 VCM
Related show

Message

Kate Hsuan Dec. 3, 2021, 12:06 p.m. UTC
v3 removes all the V4l2 hardcode from the algorithm and simplify the
AF configurations. The hardcoded AF starting area was removed and
bdsOutputSize was used to determine start_x and start_y axis.

Patch v3 squashed Daniel's commit to remove the V4l2 control from the
algorithm. Also, params->acc_param.af is simplified by using kernel's
default configuration. Since the V4l2 configuration had been removed,
the greedy algorithm is revised to fix some errors. Now, the AF area
is determined by the bdsOutputSize.

There is still some issues of bdsOutputSize to determine the AF
start position. bdsOutputSize gives a 1440x960 size of the image but
the output format is 1280x720. If the position is based on it, it will
be shifted left for 80px. 

Kate Hsuan (1):
  ipa: ipu3: af: Auto focus for dw9719 Surface Go2 VCM

 src/ipa/ipu3/algorithms/af.cpp      | 239 ++++++++++++++++++++++++++++
 src/ipa/ipu3/algorithms/af.h        |  53 ++++++
 src/ipa/ipu3/algorithms/meson.build |   3 +-
 src/ipa/ipu3/ipa_context.cpp        |  27 ++++
 src/ipa/ipu3/ipa_context.h          |  11 ++
 src/ipa/ipu3/ipu3.cpp               |   2 +
 6 files changed, 334 insertions(+), 1 deletion(-)
 create mode 100644 src/ipa/ipu3/algorithms/af.cpp
 create mode 100644 src/ipa/ipu3/algorithms/af.h