From patchwork Mon Sep 30 19:59:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacopo Mondi X-Patchwork-Id: 21439 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 9E22DC3257 for ; Mon, 30 Sep 2024 19:59:32 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 3B32163512; Mon, 30 Sep 2024 21:59:31 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="aPV4XLSt"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 1234E63502 for ; Mon, 30 Sep 2024 21:59:30 +0200 (CEST) Received: from ideasonboard.com (unknown [95.131.46.153]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id E624A280; Mon, 30 Sep 2024 21:57:57 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1727726278; bh=JHjwqWeHIk8wgeVTtA07DTkzGh1Brh4ngQbF7CCpsv0=; h=From:To:Cc:Subject:Date:From; b=aPV4XLSteJNzAHkpcJYfXQ7ZYBT9C7S9BffRTGlrCq0ewXxWV0eN/iIRwZkpwOdJM /vR0EgkTJfffTD3eVuHuyJbDAgexdYaSI5EGksR7OtIv0u3lg4JHqHaIsUUmsJRzGL bhLosLr8WfZTtq31ayQfBgoNctUBk8bUZpqLoxos= From: Jacopo Mondi To: libcamera-devel@lists.libcamera.org Cc: Jacopo Mondi , Harvey Yang Subject: [PATCH v9 0/5] Add Face Detection Controls Date: Mon, 30 Sep 2024 21:59:08 +0200 Message-ID: <20240930195915.152187-1-jacopo.mondi@ideasonboard.com> X-Mailer: git-send-email 2.46.1 MIME-Version: 1.0 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" I took over "[PATCH v8 0/3] Add Face Detection Controls" on top of the patch to the Rectangle class on which we have gone back and forth for the last week Harvey and cros team please review the first patch and test if you think it's needed. v9: - add "libcamera: geometry: Clarify Rectangle's top-left corner" - Rebase 2/5 on top of this using min(p1.y, p2.y) - Break out 3/5 from 4/5 - Reword parts of 4/5 to make it more similar to the existing controls descriptions - Make FaceDetectMode a int32_t as required by e6da224926b0 ("libcamera: controls: Handle enum values without a cast") - Use int32_t as a type for FaceDetectMode in 5/5 - Populate ANDROID_STATISTICS_FACE_SCORES with actual face scores - Populate the ANDROID_STATISTICS_FACE_DETECT_MODE metadata from settings only if present Pipeline: https://gitlab.freedesktop.org/camera/libcamera/-/pipelines/1280968 v8: Reverted back to v5 that new control ids in the draft. v7: Fixed comments. v6: - Added control_ids_android as the new control id list. - Moved the new control ids there, instead of in draft. v5: - Rewrote Rectangle's c'tor that allows any two diagonal points. - Added unit tests. v4: - Added support of FaceDetectModeFull and FaceDetectFaceIds. - Fixed descriptions of control sizes. v3: Applied fixes according to Jacopo's comments. - Moved the new face detection controls from core to draft. - Amended new controls' descriptions. v2: - Squashed the fourth CL into the last patch, as it's a fix. - Fixed CLs based on checkstyle's suggestions. Harvey Yang (1): libcamera: android: Add face detection control support Jacopo Mondi (1): libcamera: geometry: Clarify Rectangle's top-left corner Yudhistira Erlandinata (3): libcamera: geometry: Add two-point Rectangle constructor libcamera: controls: Add ControlTypePoint libcamera: control_ids_draft: Add face detection controls include/libcamera/controls.h | 6 ++ include/libcamera/geometry.h | 7 ++ src/android/camera_capabilities.cpp | 44 +++++++- src/android/camera_device.cpp | 66 +++++++++++- src/libcamera/control_ids_draft.yaml | 82 +++++++++++++++ src/libcamera/controls.cpp | 6 ++ src/libcamera/geometry.cpp | 151 +++++++++++++++++++++++++++ test/geometry.cpp | 14 +++ 8 files changed, 370 insertions(+), 6 deletions(-) --- 2.46.1