Patch Detail
Show a patch.
GET /api/patches/14083/?format=api
{ "id": 14083, "url": "https://patchwork.libcamera.org/api/patches/14083/?format=api", "web_url": "https://patchwork.libcamera.org/patch/14083/", "project": { "id": 1, "url": "https://patchwork.libcamera.org/api/projects/1/?format=api", "name": "libcamera", "link_name": "libcamera", "list_id": "libcamera_core", "list_email": "libcamera-devel@lists.libcamera.org", "web_url": "", "scm_url": "", "webscm_url": "" }, "msgid": "<tencent_F9B29C0540D154916E5F7D791BA4D254A009@qq.com>", "date": "2021-10-11T12:48:24", "name": "[libcamera-devel,RFC,v2] libcamera: isp: Add ISP class", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "c45e8682c01f2a642644fa13d435bb4a77cfca70", "submitter": { "id": 88, "url": "https://patchwork.libcamera.org/api/people/88/?format=api", "name": "Siyuan Fan", "email": "siyuan.fan@foxmail.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/14083/mbox/", "series": [ { "id": 2612, "url": "https://patchwork.libcamera.org/api/series/2612/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=2612", "date": "2021-10-11T12:48:24", "name": "[libcamera-devel,RFC,v2] libcamera: isp: Add ISP class", "version": 2, "mbox": "https://patchwork.libcamera.org/series/2612/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/14083/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/14083/checks/", "tags": {}, "headers": { "Return-Path": "<libcamera-devel-bounces@lists.libcamera.org>", "X-Original-To": "parsemail@patchwork.libcamera.org", "Delivered-To": "parsemail@patchwork.libcamera.org", "Received": [ "from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 90127C323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 11 Oct 2021 12:48:38 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 0B77468F50;\n\tMon, 11 Oct 2021 14:48:38 +0200 (CEST)", "from out203-205-221-153.mail.qq.com (out203-205-221-153.mail.qq.com\n\t[203.205.221.153])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id B62E16012B\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 11 Oct 2021 14:48:34 +0200 (CEST)", "from localhost.localdomain ([36.112.203.237])\n\tby newxmesmtplogicsvrszb6.qq.com (NewEsmtp) with SMTP\n\tid C1AB4444; Mon, 11 Oct 2021 20:48:26 +0800" ], "Authentication-Results": "lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=foxmail.com header.i=@foxmail.com\n\theader.b=\"yZHLxLfp\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=foxmail.com;\n\ts=s201512; t=1633956510;\n\tbh=4lNCq3NSsh4bs2xqdhTjA537TG4js5UXWvZRWRt4yLI=;\n\th=From:To:Cc:Subject:Date;\n\tb=yZHLxLfpeNGjnGYp0Fs74exKGEVvb8Nyn8CyJeHb3eN2xT7EPKs81uouqF7Sx2qHH\n\tu79Ul24yL2vlkL/ZkECnSDqIIz6Zru96eV6/8OZAbshiuCjE332WWU+/nlb+P90ik9\n\tPtd8xg49L+swV9u4RlYkKLxj5Hrt+0C0gg71Oeao=", "X-QQ-mid": "xmsmtpt1633956506toxwbmoxx", "Message-ID": "<tencent_F9B29C0540D154916E5F7D791BA4D254A009@qq.com>", "X-QQ-XMAILINFO": "MHMAY6vlphTX2rkY/SFXpD1x/JxpH/q49rD+N/XMDqlMz5y/uwPTY0sRIoIgET\n\tz1axKATaKhnJ9OsNZxPnqBe8qbrPPsB0Cy1KbIFhqA1CLokVWS8eqPe/xbfjHiJfTpBcuCRVFKPD\n\tMlYVtStGC90A/rbhhwNuXw85YlgzlCFmRAQ8l9rtxw/aXReSzsDaWlyEWhb34xezWPS0nv7NNWeu\n\tJDvVmFasxyZ8rcCe+Jm+OxDYQhwzzbqhCvoSHDS2kWfWKtYFLVit3Vh1r8dQjabw400ju0jOx44+\n\tSkq5+LzHq1Pr9YqFSNUaotDeAkEN9E8UBuf1MBvEKDClVB6vCFi7QBVeAnB217j2PMxbXCkuXt/2\n\tkuQZlId0NoYolbJflbdZMmrYCTlxk5rQ1l972MsqUVpXndORPc06435HK+lJplqEr155rF+XYOOK\n\top/OWBGWWMSyoClWoS2vmFnfiIXkxLmRkeJiljJNJjJesiOJ4eonuyQ0uOKPWrCZS+3LWEwxQlpN\n\tggUYkwraZj/bBCY1jKJbTZ7rHs35LE41WGOuwpD1eYdWtMYAqY5sH9JXQbX6PUU6JmythIAgc8w8\n\t4vJ85Mp2HtbpqG1h4yEchoKP6pPvpW+mBzyAgeppA8r0GenMrs9RiLgRsZ14kBCWIJJX7hqZSusQ\n\tpXbKz90WRwSRh018Bo42WEEtftdXT9cDoqUO5GU7vpOF/LCxzNwhKyBQhtX/9eaUr8SFoCTI3ebm\n\tVHpHpiaqQrihp4vKwW2BiFN9YtaKH0sANMl/4YRVGh6aNIW8YwnGOSjvrU1rdLFxyy6al1jBm9vZ\n\tLKePfT+C2lRbdVck7y+hAq4iZd38gppS+kLXqL4tdAsoOVq8R4aheHWlsJdRT/2rnC4rO2EYVTIA\n\t==", "From": "Siyuan Fan <siyuan.fan@foxmail.com>", "To": "libcamera-devel@lists.libcamera.org", "Date": "Mon, 11 Oct 2021 13:48:24 +0100", "X-OQ-MSGID": "<20211011124824.4756-1-siyuan.fan@foxmail.com>", "X-Mailer": "git-send-email 2.20.1", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[libcamera-devel] [RFC PATCH v2] libcamera: isp: Add ISP class", "X-BeenThere": "libcamera-devel@lists.libcamera.org", "X-Mailman-Version": "2.1.29", "Precedence": "list", "List-Id": "<libcamera-devel.lists.libcamera.org>", "List-Unsubscribe": "<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>", "List-Archive": "<https://lists.libcamera.org/pipermail/libcamera-devel/>", "List-Post": "<mailto:libcamera-devel@lists.libcamera.org>", "List-Help": "<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>", "List-Subscribe": "<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>", "Errors-To": "libcamera-devel-bounces@lists.libcamera.org", "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>" }, "content": "From: Fan Siyuan <siyuan.fan@foxmail.com>\n\nThis version adds the isp statistics struct and two signals, which should\nbe connected to corresponding seperate functions.\n\nSigned-off-by: Fan Siyuan <siyuan.fan@foxmail.com>\n---\n include/libcamera/internal/isp.h | 102 +++++++++++++++++++++++++++++++\n 1 file changed, 102 insertions(+)\n create mode 100644 include/libcamera/internal/isp.h", "diff": "diff --git a/include/libcamera/internal/isp.h b/include/libcamera/internal/isp.h\nnew file mode 100644\nindex 00000000..4b4c38e7\n--- /dev/null\n+++ b/include/libcamera/internal/isp.h\n@@ -0,0 +1,102 @@\n+/* SPDX-License-Identifier: LGPL-2.1-or-later */\n+/*\n+ * Copyright (C) 2021, Siyuan Fan <siyuan.fan@foxmail.com>\n+ *\n+ * isp.h - The software ISP abstract base class\n+ */\n+#ifndef __LIBCAMERA_INTERNAL_ISP_H__\n+#define __LIBCAMERA_INTERNAL_ISP_H__\n+\n+#include <vector>\n+#include <memory>\n+\n+#include <libcamera/formats.h>\n+#include <libcamera/framebuffer.h>\n+#include <libcamera/geometry.h>\n+#include <libcamera/pixel_format.h>\n+\n+#include \"libcamera/base/object.h\"\n+#include \"libcamera/base/signal.h\"\n+\n+namespace libcamera{\n+\n+class ISP : public Object\n+{\n+public:\n+ ISP() {}\n+\n+ virtual ~ISP() {}\n+\n+ virtual int configure(PixelFormat &inputFormat, PixelFormat &outputFormat, Size &inputSize, Size &outputSize) = 0;\n+\n+ virtual void processing(struct isp_stats *stats, FrameBuffer *srcBuffer, FrameBuffer *dstBuffer, int width, int height) = 0;\n+\n+ virtual void calculating(struct isp_stats* stats, FrameBuffer *srcBuffer) = 0;\n+\n+ virtual int exportBuffers(std::vector<std::unique_ptr<FrameBuffer>> *buffers, unsigned int count, int width, int height) = 0;\n+\n+ virtual int exportStats(struct isp_stats *stats) = 0;\n+\n+ virtual void start() = 0;\n+\n+ virtual void stop() = 0;\n+\n+ Signal<FrameBuffer *, FrameBuffer *> ispCompleted;\n+ Signal<struct isp_stats *, FrameBuffer *> calcStats;\n+ Signal<struct isp_stats *, FrameBuffer *, FrameBuffer *, int, int> imgProcess;\n+\n+ struct isp_black_level {\n+ __u32 enabled;\n+ __u16 bl_r;\n+ __u16 bl_gr;\n+ __u16 bl_gb;\n+ __u16 bl_b;\n+ };\n+\n+ struct isp_lens_shading {\n+ __u32 enabled;\n+ __u16 grid[16][16];\n+ };\n+\n+ struct isp_denoise_raw {\n+ __u32 enabled;\n+ };\n+\n+ struct isp_auto_white_balance {\n+ __u32 enabled;\n+ __u64 r_mean;\n+ __u64 g_mean;\n+ __u64 b_mean;\n+ };\n+\n+ struct isp_gamma_correct {\n+ __u32 enabled;\n+ __u16 gammaX[33];\n+ __u16 gammaY[33];\n+ };\n+\n+ struct isp_color_correct {\n+ __u32 enabled;\n+ __s32 ccm[3][3];\n+ };\n+\n+ struct isp_histogram {\n+ __u32 r_hist[1024];\n+ __u32 g_hist[1024];\n+ __u32 b_hist[1024];\n+ };\n+\n+ struct isp_stats {\n+ struct isp_black_level isp_bl;\n+ struct isp_lens_shading isp_ls;\n+ struct isp_denoise_raw isp_dr;\n+ struct isp_auto_white_balance isp_awb;\n+ struct isp_gamma_correct isp_gc;\n+ struct isp_color_correct isp_cc;\n+ struct isp_histogram isp_hist;\n+ }; \n+};\n+\n+} /* namespace libcamera */\n+\n+#endif /* __LIBCAMERA_INTERNAL_ISP_H__ */\n", "prefixes": [ "libcamera-devel", "RFC", "v2" ] }