[20/35] libcamera: software_isp: lut: Make gain corrected CCM in lut.cpp available in debayer params
diff mbox series

Message ID 20250611013245.133785-21-bryan.odonoghue@linaro.org
State New
Headers show
Series
  • Add GLES 2.0 GPUISP to libcamera
Related show

Commit Message

Bryan O'Donoghue June 11, 2025, 1:32 a.m. UTC
There is another CCM calculated in this algorithm callback, this time based
on the LUT.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
 src/ipa/simple/algorithms/lut.cpp | 1 +
 1 file changed, 1 insertion(+)

Comments

Bryan O'Donoghue June 16, 2025, 7:26 p.m. UTC | #1
On 11/06/2025 02:32, Bryan O'Donoghue wrote:
> There is another CCM calculated in this algorithm callback, this time based
> on the LUT.
> 
> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> ---
>   src/ipa/simple/algorithms/lut.cpp | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/src/ipa/simple/algorithms/lut.cpp b/src/ipa/simple/algorithms/lut.cpp
> index d1d5f727..a161adb1 100644
> --- a/src/ipa/simple/algorithms/lut.cpp
> +++ b/src/ipa/simple/algorithms/lut.cpp
> @@ -126,6 +126,7 @@ void Lut::prepare(IPAContext &context,
>   		auto &red = params->redCcm;
>   		auto &green = params->greenCcm;
>   		auto &blue = params->blueCcm;
> +		params->ccm = ccm;


Pardon me, I copy/pasted my second reply to patch #19 which was meant 
for patch #20.

Reposting here:

Ping Milan

Or is this additional latch in lut relevant ?

Its not 100% clear to me - I could trace the data inside of IPA or I
could just ask someone like you who knows the IPA code better.

---
bod
Milan Zamazal June 17, 2025, 1:55 p.m. UTC | #2
Bryan O'Donoghue <bryan.odonoghue@linaro.org> writes:

> There is another CCM calculated in this algorithm callback, this time based
> on the LUT.

The commit message should be reworded if the preceding patch gets
dropped; as for the change itself:

Reviewed-by: Milan Zamazal <mzamazal@redhat.com>

> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> ---
>  src/ipa/simple/algorithms/lut.cpp | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/src/ipa/simple/algorithms/lut.cpp b/src/ipa/simple/algorithms/lut.cpp
> index d1d5f727..a161adb1 100644
> --- a/src/ipa/simple/algorithms/lut.cpp
> +++ b/src/ipa/simple/algorithms/lut.cpp
> @@ -126,6 +126,7 @@ void Lut::prepare(IPAContext &context,
>  		auto &red = params->redCcm;
>  		auto &green = params->greenCcm;
>  		auto &blue = params->blueCcm;
> +		params->ccm = ccm;
>  		for (unsigned int i = 0; i < DebayerParams::kRGBLookupSize; i++) {
>  			red[i].r = ccmValue(i, ccm[0][0]);
>  			red[i].g = ccmValue(i, ccm[1][0]);

Patch
diff mbox series

diff --git a/src/ipa/simple/algorithms/lut.cpp b/src/ipa/simple/algorithms/lut.cpp
index d1d5f727..a161adb1 100644
--- a/src/ipa/simple/algorithms/lut.cpp
+++ b/src/ipa/simple/algorithms/lut.cpp
@@ -126,6 +126,7 @@  void Lut::prepare(IPAContext &context,
 		auto &red = params->redCcm;
 		auto &green = params->greenCcm;
 		auto &blue = params->blueCcm;
+		params->ccm = ccm;
 		for (unsigned int i = 0; i < DebayerParams::kRGBLookupSize; i++) {
 			red[i].r = ccmValue(i, ccm[0][0]);
 			red[i].g = ccmValue(i, ccm[1][0]);