From patchwork Wed Nov 24 10:34:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kate Hsuan X-Patchwork-Id: 14747 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id DE595BDB13 for ; Wed, 24 Nov 2021 10:35:06 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 3858760233; Wed, 24 Nov 2021 11:35:06 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.b="AR7bsYMo"; dkim-atps=neutral Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 1B9036022F for ; Wed, 24 Nov 2021 11:35:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1637750102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3Qu6+xluIlYV36QQ3XXPpLThZ1oRFPRK9oImm5QHigQ=; b=AR7bsYMo1RbI1mhhy6NmSpXfavhrfL2qdB9R1KWRIKNDbY8vzbF/GIHPUDBZA4chqkHE1k j4wCvpKWPUaOXYG9Lku027txiKLAIvI7DEbjGxR85TWtnQG8ScMiCLjoMcOGmLezHQc1UX qUnWZf/NOrw6K/H0utvH5HtgKkDIGvA= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-336-R8754BU9OTeNj0lrhEBqgg-1; Wed, 24 Nov 2021 05:35:01 -0500 X-MC-Unique: R8754BU9OTeNj0lrhEBqgg-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 231D1425CC for ; Wed, 24 Nov 2021 10:35:01 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.39.195.110]) by smtp.corp.redhat.com (Postfix) with ESMTP id 17C8C10027D0; Wed, 24 Nov 2021 10:34:58 +0000 (UTC) From: Kate Hsuan To: libcamera devel Date: Wed, 24 Nov 2021 18:34:46 +0800 Message-Id: <20211124103447.102069-1-hpa@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=hpa@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [libcamera-devel] [RFC v2 0/1] ipa: ipu3: af: Auto focus for dw9719 Surface Go2 VCM X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The v1 patch provides a POC implementation of the IPU3 auto focus algorithm. In this v2 patch, the grid configuration interface and IPU3 AF accelerator configuration are also added into the AF class. Also, the default AF area is moved from the top left corner of the sensor to the center of the sensor and can be configured in configure(). Documents of the class and variable are also added. For the hardcoded VCM control, I'm still trying to understand the control architecture. Please allow me more time to move them to the correct place. Kate Hsuan (1): ipa: ipu3: af: Auto focus for dw9719 Surface Go2 VCM src/ipa/ipu3/algorithms/af.cpp | 284 ++++++++++++++++++++++++++++ src/ipa/ipu3/algorithms/af.h | 54 ++++++ src/ipa/ipu3/algorithms/agc.cpp | 2 +- src/ipa/ipu3/algorithms/meson.build | 3 +- src/ipa/ipu3/ipa_context.cpp | 26 +++ src/ipa/ipu3/ipa_context.h | 11 ++ src/ipa/ipu3/ipu3.cpp | 2 + 7 files changed, 380 insertions(+), 2 deletions(-) create mode 100644 src/ipa/ipu3/algorithms/af.cpp create mode 100644 src/ipa/ipu3/algorithms/af.h