[v3,18/22] libcamera: software_isp: debayer: Make the debayer_ object of type class Debayer not DebayerCpu
diff mbox series

Message ID 20251202133157.661407-19-bryan.odonoghue@linaro.org
State New
Headers show
Series
  • GPUISP precursor series
Related show

Commit Message

Bryan O'Donoghue Dec. 2, 2025, 1:31 p.m. UTC
Make the type of object Debayer not DebayerCpu thus allowing us to assign
the object to either DebayerCpu or DebayerEGL.

Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Milan Zamazal <mzamazal@redhat.com>
Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
 include/libcamera/internal/software_isp/software_isp.h | 5 ++---
 src/libcamera/software_isp/software_isp.cpp            | 6 +++---
 2 files changed, 5 insertions(+), 6 deletions(-)

Patch
diff mbox series

diff --git a/include/libcamera/internal/software_isp/software_isp.h b/include/libcamera/internal/software_isp/software_isp.h
index 786246592..ad89c9b3c 100644
--- a/include/libcamera/internal/software_isp/software_isp.h
+++ b/include/libcamera/internal/software_isp/software_isp.h
@@ -37,7 +37,7 @@ 
 
 namespace libcamera {
 
-class DebayerCpu;
+class Debayer;
 class FrameBuffer;
 class PixelFormat;
 class Stream;
@@ -94,8 +94,7 @@  private:
 	void statsReady(uint32_t frame, uint32_t bufferId);
 	void inputReady(FrameBuffer *input);
 	void outputReady(FrameBuffer *output);
-
-	std::unique_ptr<DebayerCpu> debayer_;
+	std::unique_ptr<Debayer> debayer_;
 	Thread ispWorkerThread_;
 	SharedMemObject<DebayerParams> sharedParams_;
 	DebayerParams debayerParams_;
diff --git a/src/libcamera/software_isp/software_isp.cpp b/src/libcamera/software_isp/software_isp.cpp
index c0ff91cc4..638d9a6e6 100644
--- a/src/libcamera/software_isp/software_isp.cpp
+++ b/src/libcamera/software_isp/software_isp.cpp
@@ -267,7 +267,7 @@  int SoftwareIsp::configure(const StreamConfiguration &inputCfg,
 
 	ispWorkerThread_.start();
 
-	ret = debayer_->invokeMethod(&DebayerCpu::configure,
+	ret = debayer_->invokeMethod(&Debayer::configure,
 				     ConnectionTypeBlocking, inputCfg,
 				     outputCfgs, ccmEnabled_);
 	if (ret) {
@@ -367,7 +367,7 @@  int SoftwareIsp::start()
  */
 void SoftwareIsp::stop()
 {
-	debayer_->invokeMethod(&DebayerCpu::stop,
+	debayer_->invokeMethod(&Debayer::stop,
 			       ConnectionTypeBlocking);
 
 	ispWorkerThread_.exit();
@@ -401,7 +401,7 @@  void SoftwareIsp::stop()
 void SoftwareIsp::process(uint32_t frame, FrameBuffer *input, FrameBuffer *output)
 {
 	ipa_->computeParams(frame);
-	debayer_->invokeMethod(&DebayerCpu::process,
+	debayer_->invokeMethod(&Debayer::process,
 			       ConnectionTypeQueued, frame, input, output, debayerParams_);
 }