pmaports/temp/libcamera/0002-libcamera-simple-Force-disable-softwareISP-for-milli.patch
Robert Mader c54777db04
temp/libcamera: upgrade to 0.3.1 (MR 5381)
Rebase our downstream patches and drop the one included in the release.

See https://gitlab.freedesktop.org/camera/libcamera/-/releases/v0.3.1

Notes:
 - The abi-compliance checker reports 100% binary and source compatibility,
   so this release does not change the SONAME.
 - qcam has been ported to QT6.
 - This release has some notable improvements to the PPP/rkisp1, however
   lower frame rates might be encountered sometimes. This will hopefully
   get fixed in the imx258 driver in Linux 6.11.
 - The swISP got some fixes but nothing major apart from the patch we
   were already carrying.

[ci:skip-build]: already built successfully in CI
2024-07-25 22:32:58 +02:00

43 lines
1.3 KiB
Diff

From 2531eab53574092da0451f4f3b7e5dbc7f9ecd13 Mon Sep 17 00:00:00 2001
From: Robert Mader <robert.mader@collabora.com>
Date: Thu, 9 May 2024 21:07:07 +0200
Subject: [PATCH 2/4] libcamera: simple: Force-disable softwareISP for
millipixels
As the later uses libcamera and requires raw-streams to get passed
through. In the future, libcamera will likely support both - raw and
swIsp - at the same time.
---
src/libcamera/pipeline/simple/simple.cpp | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/src/libcamera/pipeline/simple/simple.cpp b/src/libcamera/pipeline/simple/simple.cpp
index b6b8f854..86285bc4 100644
--- a/src/libcamera/pipeline/simple/simple.cpp
+++ b/src/libcamera/pipeline/simple/simple.cpp
@@ -7,6 +7,7 @@
*/
#include <algorithm>
+#include <fstream>
#include <iterator>
#include <list>
#include <map>
@@ -1544,6 +1545,14 @@ bool SimplePipelineHandler::match(DeviceEnumerator *enumerator)
swIspEnabled_ = info->swIspEnabled;
+ std::string comm_string;
+ std::ifstream("/proc/self/comm") >> comm_string;
+ if (comm_string == "millipixels") {
+ LOG(SimplePipeline, Warning)
+ << "Detected millipixels, disabling swIsp";
+ swIspEnabled_ = false;
+ }
+
/* Locate the sensors. */
std::vector<MediaEntity *> sensors = locateSensors();
if (sensors.empty()) {
--
2.45.2