From aa2fe6a86f260a9351621af3c110ee0fcbac7e8d Mon Sep 17 00:00:00 2001 From: Naushir Patuck Date: Thu, 6 Oct 2022 14:17:39 +0100 Subject: pipeline: ipa: raspberrypi: Add HBLANK control to DelayedControls Update CamHelper::getDelays() to return the sensor HBLANK delay. The HBLANK delay is set to the same value as VBLANK delay for all sensors in the Raspberry Pi IPA. Return the HBLANK gain delay from the IPA to the pipeline handler, and initialise DelayedControls to handle V4L2_CID_HBLANK with this delay value. As a drive-by, check that the V4L2_CID_HBLANK control is available when calling IPARPi::configure(). Signed-off-by: Naushir Patuck Tested-by: Dave Stevenson Reviewed-by: Laurent Pinchart Signed-off-by: Laurent Pinchart --- src/ipa/raspberrypi/cam_helper_imx296.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/ipa/raspberrypi/cam_helper_imx296.cpp') diff --git a/src/ipa/raspberrypi/cam_helper_imx296.cpp b/src/ipa/raspberrypi/cam_helper_imx296.cpp index d86ff387..ecb845e7 100644 --- a/src/ipa/raspberrypi/cam_helper_imx296.cpp +++ b/src/ipa/raspberrypi/cam_helper_imx296.cpp @@ -23,7 +23,8 @@ public: double gain(uint32_t gainCode) const override; uint32_t exposureLines(const Duration exposure, const Duration lineLength) const override; Duration exposure(uint32_t exposureLines, const Duration lineLength) const override; - void getDelays(int &exposureDelay, int &gainDelay, int &vblankDelay) const override; + void getDelays(int &exposureDelay, int &gainDelay, + int &vblankDelay, int &hblankDelay) const override; private: static constexpr uint32_t minExposureLines = 1; @@ -66,11 +67,12 @@ Duration CamHelperImx296::exposure(uint32_t exposureLines, } void CamHelperImx296::getDelays(int &exposureDelay, int &gainDelay, - int &vblankDelay) const + int &vblankDelay, int &hblankDelay) const { exposureDelay = 2; gainDelay = 2; vblankDelay = 2; + hblankDelay = 2; } static CamHelper *create() -- cgit v1.2.1