{"id":10494,"url":"https://patchwork.libcamera.org/api/1.1/covers/10494/?format=json","web_url":"https://patchwork.libcamera.org/cover/10494/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20201125113640.20246-1-david.plowman@raspberrypi.com>","date":"2020-11-25T11:36:37","name":"[libcamera-devel,0/3] Raspberry Pi AGC improvements","submitter":{"id":42,"url":"https://patchwork.libcamera.org/api/1.1/people/42/?format=json","name":"David Plowman","email":"david.plowman@raspberrypi.com"},"mbox":"https://patchwork.libcamera.org/cover/10494/mbox/","series":[{"id":1481,"url":"https://patchwork.libcamera.org/api/1.1/series/1481/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=1481","date":"2020-11-25T11:36:37","name":"Raspberry Pi AGC improvements","version":1,"mbox":"https://patchwork.libcamera.org/series/1481/mbox/"}],"comments":"https://patchwork.libcamera.org/api/covers/10494/comments/","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 15828BE08A\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 25 Nov 2020 11:36:46 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 9C2BF6340B;\n\tWed, 25 Nov 2020 12:36:45 +0100 (CET)","from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com\n\t[IPv6:2a00:1450:4864:20::32d])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 15593633E5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 25 Nov 2020 12:36:44 +0100 (CET)","by mail-wm1-x32d.google.com with SMTP id c198so1724771wmd.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 25 Nov 2020 03:36:44 -0800 (PST)","from pi4-davidp.lan (plowpeople3.plus.com. [80.229.223.72])\n\tby smtp.gmail.com with ESMTPSA id\n\tb14sm4232371wrq.47.2020.11.25.03.36.42\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tWed, 25 Nov 2020 03:36:42 -0800 (PST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"I7QR2hMt\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=from:to:cc:subject:date:message-id:mime-version\n\t:content-transfer-encoding;\n\tbh=eAq61bDKq2Q2r9NvGmXj67CXN/Yz2XN5ex9tN8GiTyk=;\n\tb=I7QR2hMtzmZV0FypR3DL/faE0ZcRhgBcAejVbdcsLm3kruyK08+saD8JsI2CgdTvbc\n\tHnwTrBSDHH82W4rSAKkLqlaxk54ufgWeLU3Ctgzq5ajE4yjJMMxRobsjk0JNp8ukJObr\n\tVd+v9GRRM6kWRJjq5t6ST2OuB1u1N1LnJMcSVatjG1TyaXGdhxp2O1LYIwCODMsT9vnm\n\tPVfysaxMv0R3jutlPS9m4qfl45lkHhiBVej6aM+bkyRH5vpvofdjVtVWoA8/bANi/+ER\n\tv2HIOOURehkRaiqAQvYNNDFisIdEBtpOQ6bcMVMGIRETToQoMQ36QRaSYxUM0Bw+gGkA\n\tDNBA==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version\n\t:content-transfer-encoding;\n\tbh=eAq61bDKq2Q2r9NvGmXj67CXN/Yz2XN5ex9tN8GiTyk=;\n\tb=k2NOHqsbfGILBe49VYBsaK0FPTHRg9HP0XLRh2GmVp3fzaBhSAPL1ZGNu33V4bQHBm\n\tn0M8m3c6vNb0zrrmlwMNLsDbdfFaRiKPVm5mF2QT3Kf9XinKuJXs7doIjym7ZYrvdWtt\n\tiHYhhu2no630ouDsHVn2dOVhyOlzIu+BEqDySdv/1xtcXeqPzT7aGFUIZXK2+cnWaeiJ\n\tWVgnoS9l2DZOBJwNfObvQJVMaAFCbd7tY7Hs+5HIRW9qwfljkI66Out/zkxMWLOhj7FG\n\t6uRfjsZraZuJwYPmdTnjcI21c9U8/pv0Rc0mkPFOS1aftIyxYX/+QbPPjU399qxHtuZ1\n\trBFA==","X-Gm-Message-State":"AOAM5311vE6Ubo8Rr2xxVmIQblv6vISGif28wrWJjlJ3TW/1O1eOjNws\n\tAiYLzzHF9tLKjWKaHopJw/UF2xBQj9WM62zH","X-Google-Smtp-Source":"ABdhPJw3OIIzch4dqI5xB0iIVPmSjnHZ69uzYNRLwtJvmrLXi7Tg8gyutZHK5dm0TbZv6khyT4twZw==","X-Received":"by 2002:a1c:e305:: with SMTP id a5mr3400391wmh.45.1606304203317; \n\tWed, 25 Nov 2020 03:36:43 -0800 (PST)","From":"David Plowman <david.plowman@raspberrypi.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Wed, 25 Nov 2020 11:36:37 +0000","Message-Id":"<20201125113640.20246-1-david.plowman@raspberrypi.com>","X-Mailer":"git-send-email 2.20.1","MIME-Version":"1.0","Subject":"[libcamera-devel] [PATCH 0/3] Raspberry Pi AGC improvements","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>","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"Hi everyone\n\nThanks to Kieran for merging my previous AGC patches. I think I\nmentioned then that there would still be a few more to come - though\nnothing of great complexity - so here's the first few.\n\nI think only the second of these patches rises above the level of\n\"fairly trivial\", so it would certainly be good for Naush to review\nthat one! We have:\n\n1. When setting explicit shutter and gain values, the AGC would adapt\n slowly towards them. I think users would expect it to \"jump\" there\n immediately.\n\n2. This patch stops us ever turning the AGC off even when it's\n disabled. Instead we put it into \"fixed shutter and gain\" mode, using\n the last values we saw. This is better because, if you then set the\n gain (for example), the shutter won't start \"floating\" again (which\n was the previous behaviour and, I think, unexpected for users).\n\n3. Fixes some AGC oscillation problems (particularly at startup) with\n the imx219, caused by the fact that the sensor metadata isn't working\n for us. This means things can be unstable if we request exposures or\n gains that the sensor can't deliver (we have the same situation with\n the ov5647).\n\nSubsequent to these I do have a couple more AGC changes ready to go,\nmostly related to figuring out the correct number of frames to drop\nwhen the camera starts. However, these are dependent on Naush's\nCamera::start() patch set (or some equivalent variation thereof), so\nmight I give that one a little nudge in passing please?\n\nThanks and best regards\nDavid\n\nDavid Plowman (3):\n  src: ipa: raspberrypi: Avoid AGC filtering when both gain and shutter\n    specified\n  src: ipa: raspberrypi: Improve behaviour when AE disabled\n  src: ipa: raspberrypi: Fix initial AGC oscillation for imx219 sensor\n\n src/ipa/raspberrypi/controller/rpi/agc.cpp |  7 +++-\n src/ipa/raspberrypi/data/imx219.json       |  4 +-\n src/ipa/raspberrypi/raspberrypi.cpp        | 48 ++++++++++++++--------\n 3 files changed, 38 insertions(+), 21 deletions(-)"}