Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package prison-qt5 for openSUSE:Factory 
checked in at 2022-06-17 21:19:45
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/prison-qt5 (Old)
 and      /work/SRC/openSUSE:Factory/.prison-qt5.new.1548 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "prison-qt5"

Fri Jun 17 21:19:45 2022 rev:68 rq:982306 version:5.95.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/prison-qt5/prison-qt5.changes    2022-05-16 
18:09:36.185329983 +0200
+++ /work/SRC/openSUSE:Factory/.prison-qt5.new.1548/prison-qt5.changes  
2022-06-17 21:21:53.586753206 +0200
@@ -1,0 +2,17 @@
+Fri Jun 10 14:12:50 UTC 2022 - Christophe Giboudeaux <christo...@krop.fr>
+
+- Update to 5.95.0
+  * New feature release
+  * For more details please see:
+  * https://kde.org/announcements/frameworks/5/5.95.0
+- Changes since 5.94.0:
+  * Let the ForwardingHeaders be found at build time too
+  * Remove PREFIX from ecm_generate_headers for PrisonScanner
+  * Fix decimal/hexadecimal mix-up in the binary detection heuristic
+  * Simplify headers installation location
+  * Install the ForwardingHeaders in Prison/ in the builddir
+  * cmake: add purpose property to 3d-party libraries
+  * Improve Prison documentation
+  * Handle video frames with a non-standard row stride correctly as well
+
+-------------------------------------------------------------------

Old:
----
  prison-5.94.0.tar.xz
  prison-5.94.0.tar.xz.sig

New:
----
  prison-5.95.0.tar.xz
  prison-5.95.0.tar.xz.sig

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ prison-qt5.spec ++++++
--- /var/tmp/diff_new_pack.8i4vqW/_old  2022-06-17 21:21:54.102753486 +0200
+++ /var/tmp/diff_new_pack.8i4vqW/_new  2022-06-17 21:21:54.106753488 +0200
@@ -19,7 +19,7 @@
 %define sonum   5
 %define rname prison
 %define _libname KF5Prison
-%define _tar_path 5.94
+%define _tar_path 5.95
 # Full KF5 version (e.g. 5.33.0)
 %{!?_kf5_version: %global _kf5_version %{version}}
 # Last major and minor KF5 version (e.g. 5.33)
@@ -27,7 +27,7 @@
 # Only needed for the package signature condition
 %bcond_without released
 Name:           prison-qt5
-Version:        5.94.0
+Version:        5.95.0
 Release:        0
 Summary:        Barcode abstraction layer library
 License:        MIT


++++++ prison-5.94.0.tar.xz -> prison-5.95.0.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/CMakeLists.txt 
new/prison-5.95.0/CMakeLists.txt
--- old/prison-5.94.0/CMakeLists.txt    2022-05-06 13:22:05.000000000 +0200
+++ new/prison-5.95.0/CMakeLists.txt    2022-06-04 10:25:17.000000000 +0200
@@ -1,11 +1,11 @@
 cmake_minimum_required(VERSION 3.16)
 
-set(KF_VERSION "5.94.0") # handled by release scripts
+set(KF_VERSION "5.95.0") # handled by release scripts
 project(prison VERSION ${KF_VERSION})
 
 # ECM setup
 include(FeatureSummary)
-find_package(ECM 5.93.0 NO_MODULE)
+find_package(ECM 5.95.0 NO_MODULE)
 set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake 
Modules." URL "https://commits.kde.org/extra-cmake-modules";)
 feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND 
FATAL_ON_MISSING_REQUIRED_PACKAGES)
 set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake" "${ECM_MODULE_PATH}")
@@ -36,11 +36,17 @@
 find_package(Qt${QT_MAJOR_VERSION} ${REQUIRED_QT_VERSION} CONFIG REQUIRED Core 
Gui)
 find_package(Qt${QT_MAJOR_VERSION} ${REQUIRED_QT_VERSION} CONFIG 
OPTIONAL_COMPONENTS Quick Multimedia)
 find_package(QRencode)
-set_package_properties(QRencode PROPERTIES TYPE REQUIRED)
+set_package_properties(QRencode PROPERTIES
+    PURPOSE "Required for generation of QRCode barcodes."
+    TYPE REQUIRED)
 find_package(Dmtx)
-set_package_properties(Dmtx PROPERTIES TYPE RECOMMENDED)
+set_package_properties(Dmtx PROPERTIES
+    PURPOSE "Required for generation of Data Matrix barcodes."
+    TYPE RECOMMENDED)
 find_package(ZXing 1.2.0)
-set_package_properties(ZXing PROPERTIES TYPE RECOMMENDED)
+set_package_properties(ZXing PROPERTIES
+    PURPOSE "Required for generation of PDF417 barcodes and for scanning of 
barcodes from live video feed."
+    TYPE RECOMMENDED)
 
 if (Qt5_POSITION_INDEPENDENT_CODE)
   set(CMAKE_POSITION_INDEPENDENT_CODE ON)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/Mainpage.dox 
new/prison-5.95.0/Mainpage.dox
--- old/prison-5.94.0/Mainpage.dox      2022-05-06 13:22:05.000000000 +0200
+++ new/prison-5.95.0/Mainpage.dox      2022-06-04 10:25:17.000000000 +0200
@@ -6,11 +6,16 @@
  *
  * \section overview Overview
  *
- * %prison has a prison::AbstractBarcode, which is the base class for the 
actual barcode generators, currently prison::QRCodeBarcode
- * and prison::DataMatrixBarcode is the two implemented barcode generators.
+ * %prison has a Prison::AbstractBarcode, which is the base class for the 
actual barcode generators. Prison currently implements barcode generators for 
the following formats:
+ * \li QRCode
+ * \li Data Matrix
+ * \li Aztec
+ * \li Code39
+ * \li Code93
+ * \li Code128
+ * \li PDF417
  *
- * %prison currently ships a BarcodeWidget, which is a QWidget with a barcode 
painted upon, as well as a BarcodeItem, which is a
- * QGraphicsItem with a barcode painted upon.
+ * %prison currently ships the org.kde.prison.Barcode QML element that can be 
used to render barcodes in QML code.
  *
  * \section supported Supported Barcode types
  *
@@ -25,6 +30,18 @@
  *
  * %prison is currently using <a 
href="https://fukuchi.org/works/qrencode/";>libqrencode</a> for generation of <a 
href="http://en.wikipedia.org/wiki/QR_Code";>QRCode</a> barcodes
  *
+ *
+ * \section scanner Prison Scanner
+ *
+ * A barcode scanner consuming a live video feed from QtMultimedia.
+ *
+ * Prison's barcode scanner can be used from C++ code using the 
Prison::VideoScanner class, or from QML using the 
org.kde.prison.scanner.VideoScanner QML element.
+ *
+ * There are standalone QML examples in tests/scanner-qt(5|6).qml demonstrating
+ * the QML API.
+ *
+ * Barcode detection is implemented using the <a 
href="https://github.com/nu-book/zxing-cpp";>ZXing</a> library, all formats 
supported by ZXing can be detected.
+ *
  */
 
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/README.md new/prison-5.95.0/README.md
--- old/prison-5.94.0/README.md 2022-05-06 13:22:05.000000000 +0200
+++ new/prison-5.95.0/README.md 2022-06-04 10:25:17.000000000 +0200
@@ -5,12 +5,17 @@
 ## Introduction
 
 Prison has a Prison::AbstractBarcode, which is the base class for the actual
-barcode generators, currently Prison::QRCodeBarcode and 
Prison::DataMatrixBarcode
-are the two implemented barcode generators.
+barcode generators. Prison currently implements barcode generators for the 
following formats:
 
-Prison currently ships a BarcodeWidget, which is a QWidget with a barcode
-painted upon, as well as a BarcodeItem, which is a QGraphicsItem with a
-barcode painted upon.
+- QRCode
+- Data Matrix
+- Aztec
+- Code39
+- Code93
+- Code128
+- PDF417
+
+Prison currently ships the org.kde.prison.Barcode QML element that can be used 
to render barcodes in QML code.
 
 ## Supported Barcode types
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/lib/CMakeLists.txt 
new/prison-5.95.0/src/lib/CMakeLists.txt
--- old/prison-5.94.0/src/lib/CMakeLists.txt    2022-05-06 13:22:05.000000000 
+0200
+++ new/prison-5.95.0/src/lib/CMakeLists.txt    2022-06-04 10:25:17.000000000 
+0200
@@ -85,40 +85,35 @@
     HEADER_NAMES
     AbstractBarcode
     Prison
-    PREFIX Prison
     REQUIRED_HEADERS Prison_HEADERS
+    OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/Prison
 )
 
-install(FILES
+set(_all_headers
     ${Prison_HEADERS}
-    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/Prison/prison
-    COMPONENT Devel
+    ${Prison_CamelCase_HEADERS}
+    ${CMAKE_CURRENT_BINARY_DIR}/prison_export.h
 )
 
-# To keep backwards compatibility we stick with this layout for KF5,
-# and use the Prison/Prison and Prison/prison layout for KF6
-if (QT_MAJOR_VERSION STREQUAL "5")
-    install(FILES
-        ${Prison_CamelCase_HEADERS}
-        DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/Prison/prison COMPONENT Devel)
+# So that the headers are found at build time
+target_include_directories(KF5Prison PUBLIC 
"$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>")
 
-    install(FILES
-        ${CMAKE_CURRENT_BINARY_DIR}/prison_export.h
+# To keep backwards compatibility with KF5, all headers are copied to 
<includedir>/KF5/Prison/prison,
+# for KF6 everything goes into <includedir>/KF6/Prison/Prison only
+if (QT_MAJOR_VERSION STREQUAL "5")
+    install(
+        FILES ${_all_headers}
         DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/Prison/prison
         COMPONENT Devel
     )
-else()
-    install(FILES
-        ${Prison_CamelCase_HEADERS}
-        DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/Prison/Prison COMPONENT Devel)
-
-    install(FILES
-        ${CMAKE_CURRENT_BINARY_DIR}/prison_export.h
-        DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/Prison
-        COMPONENT Devel
-    )
 endif()
 
+install(
+    FILES ${_all_headers}
+    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/Prison/Prison
+    COMPONENT Devel
+)
+
 if(BUILD_QCH)
     ecm_add_qch(
         KF5Prison_QCH
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/quick/barcodequickitem.h 
new/prison-5.95.0/src/quick/barcodequickitem.h
--- old/prison-5.94.0/src/quick/barcodequickitem.h      2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/src/quick/barcodequickitem.h      2022-06-04 
10:25:17.000000000 +0200
@@ -7,7 +7,7 @@
 #ifndef PRISON_BARCODEQUICKITEM_H
 #define PRISON_BARCODEQUICKITEM_H
 
-#include <prison/prison.h>
+#include <Prison/Prison>
 
 #include <QColor>
 #include <QQuickPaintedItem>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/quick/prisonquickplugin.cpp 
new/prison-5.95.0/src/quick/prisonquickplugin.cpp
--- old/prison-5.94.0/src/quick/prisonquickplugin.cpp   2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/src/quick/prisonquickplugin.cpp   2022-06-04 
10:25:17.000000000 +0200
@@ -6,7 +6,7 @@
 
 #include "barcodequickitem.h"
 
-#include <prison/prison.h>
+#include <Prison/Prison>
 
 #include <QQmlExtensionPlugin>
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/scanner/CMakeLists.txt 
new/prison-5.95.0/src/scanner/CMakeLists.txt
--- old/prison-5.94.0/src/scanner/CMakeLists.txt        2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/src/scanner/CMakeLists.txt        2022-06-04 
10:25:17.000000000 +0200
@@ -23,7 +23,6 @@
     VERSION ${KF_VERSION}
 )
 target_include_directories(KF5PrisonScanner INTERFACE 
"$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF}/PrisonScanner/>")
-target_include_directories(KF5PrisonScanner PUBLIC 
"$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>")
 target_link_libraries(KF5PrisonScanner
     PUBLIC
         Qt${QT_MAJOR_VERSION}::Multimedia
@@ -39,18 +38,16 @@
         Format
         ScanResult
         VideoScanner
-    PREFIX Prison
+    OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/Prison
     REQUIRED_HEADERS PrisonScanner_HEADERS
 )
 
-install(FILES
-    ${PrisonScanner_CamelCase_HEADERS}
-    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/PrisonScanner/Prison COMPONENT 
Devel)
-
-install(FILES
-    ${CMAKE_CURRENT_BINARY_DIR}/prisonscanner_export.h
-    ${PrisonScanner_HEADERS}
-    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/PrisonScanner/prison
+install(
+    FILES
+        ${PrisonScanner_CamelCase_HEADERS}
+        ${PrisonScanner_HEADERS}
+        ${CMAKE_CURRENT_BINARY_DIR}/prisonscanner_export.h
+    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/PrisonScanner/Prison
     COMPONENT Devel
 )
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/scanner/videoscannerframe.cpp 
new/prison-5.95.0/src/scanner/videoscannerframe.cpp
--- old/prison-5.94.0/src/scanner/videoscannerframe.cpp 2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/src/scanner/videoscannerframe.cpp 2022-06-04 
10:25:17.000000000 +0200
@@ -34,6 +34,15 @@
     return m_frame.height();
 }
 
+int VideoScannerFrame::bytesPerLine() const
+{
+#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
+    return m_frame.bytesPerLine();
+#else
+    return m_frame.bytesPerLine(0);
+#endif
+}
+
 #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
 QVideoFrame::PixelFormat VideoScannerFrame::pixelFormat() const
 #else
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/scanner/videoscannerframe_p.h 
new/prison-5.95.0/src/scanner/videoscannerframe_p.h
--- old/prison-5.94.0/src/scanner/videoscannerframe_p.h 2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/src/scanner/videoscannerframe_p.h 2022-06-04 
10:25:17.000000000 +0200
@@ -38,6 +38,7 @@
 
     int width() const;
     int height() const;
+    int bytesPerLine() const;
 #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
     QVideoFrame::PixelFormat pixelFormat() const;
 #else
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/src/scanner/videoscannerworker.cpp 
new/prison-5.95.0/src/scanner/videoscannerworker.cpp
--- old/prison-5.94.0/src/scanner/videoscannerworker.cpp        2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/src/scanner/videoscannerworker.cpp        2022-06-04 
10:25:17.000000000 +0200
@@ -40,28 +40,28 @@
     case QVideoFrame::Format_ARGB32:
     case QVideoFrame::Format_ARGB32_Premultiplied:
     case QVideoFrame::Format_RGB32:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XRGB}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XRGB, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_RGB24:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::RGB}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::RGB, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_BGRA32:
     case QVideoFrame::Format_BGRA32_Premultiplied:
     case QVideoFrame::Format_BGR32:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::BGRX}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::BGRX, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_ABGR32:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XBGR}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XBGR, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_BGR24:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::BGR}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::BGR, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_AYUV444:
     case QVideoFrame::Format_AYUV444_Premultiplied:
-        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 4}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 4}, hints);
         break;
     case QVideoFrame::Format_YUV444:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 3}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 3}, hints);
         break;
     case QVideoFrame::Format_YUV420P:
     case QVideoFrame::Format_YUV422P:
@@ -72,19 +72,19 @@
     case QVideoFrame::Format_IMC2:
     case QVideoFrame::Format_IMC3:
     case QVideoFrame::Format_IMC4:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_UYVY:
-        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 2}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 2}, hints);
         break;
     case QVideoFrame::Format_YUYV:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 2}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 2}, hints);
         break;
     case QVideoFrame::Format_Y8:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrame::Format_Y16:
-        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 1}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 1}, hints);
         break;
 
     // formats needing conversion before ZXing can consume them
@@ -110,24 +110,24 @@
     case QVideoFrameFormat::Format_ARGB8888:
     case QVideoFrameFormat::Format_ARGB8888_Premultiplied:
     case QVideoFrameFormat::Format_XRGB8888:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XRGB}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XRGB, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrameFormat::Format_BGRA8888:
     case QVideoFrameFormat::Format_BGRA8888_Premultiplied:
     case QVideoFrameFormat::Format_BGRX8888:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::BGRX}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::BGRX, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrameFormat::Format_ABGR8888:
     case QVideoFrameFormat::Format_XBGR8888:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XBGR}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::XBGR, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrameFormat::Format_RGBA8888:
     case QVideoFrameFormat::Format_RGBX8888:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::RGBX}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::RGBX, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrameFormat::Format_AYUV:
     case QVideoFrameFormat::Format_AYUV_Premultiplied:
-        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 4}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 4}, hints);
         break;
     case QVideoFrameFormat::Format_YUV420P:
     case QVideoFrameFormat::Format_YUV422P:
@@ -138,23 +138,23 @@
     case QVideoFrameFormat::Format_IMC2:
     case QVideoFrameFormat::Format_IMC3:
     case QVideoFrameFormat::Format_IMC4:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrameFormat::Format_UYVY:
-        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 2}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 2}, hints);
         break;
     case QVideoFrameFormat::Format_YUYV:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 2}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 2}, hints);
         break;
     case QVideoFrameFormat::Format_Y8:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine()}, hints);
         break;
     case QVideoFrameFormat::Format_Y16:
-        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 1}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits() + 1, frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 1}, hints);
         break;
     case QVideoFrameFormat::Format_P010:
     case QVideoFrameFormat::Format_P016:
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, 0, 1}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine(), 1}, hints);
         break;
 
     // formats needing conversion before ZXing can consume them
@@ -162,7 +162,7 @@
     case QVideoFrameFormat::Format_SamplerExternalOES:
     case QVideoFrameFormat::Format_SamplerRect:
         frame.convertToImage();
-        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum}, hints);
+        zxRes = ZXing::ReadBarcode({frame.bits(), frame.width(), 
frame.height(), ZXing::ImageFormat::Lum, frame.bytesPerLine()}, hints);
         break;
     }
 #endif
@@ -178,7 +178,7 @@
             return c > 255;
         });
         const auto hasControlChars = std::any_of(zxRes.text().begin(), 
zxRes.text().end(), [](auto c) {
-            return c < 20 && c != 0x0a && c != 0x0d;
+            return c < 0x20 && c != 0x0a && c != 0x0d;
         });
         if (hasWideChars || !hasControlChars) {
             res->content = 
QString::fromStdString(ZXing::TextUtfEncoding::ToUtf8(zxRes.text()));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/CMakeLists.txt 
new/prison-5.95.0/tests/CMakeLists.txt
--- old/prison-5.94.0/tests/CMakeLists.txt      2022-05-06 13:22:05.000000000 
+0200
+++ new/prison-5.95.0/tests/CMakeLists.txt      2022-06-04 10:25:17.000000000 
+0200
@@ -1,3 +1,3 @@
-add_executable(test-prison)
-target_sources(test-prison PRIVATE prison.cpp barcodeexamplewidget.cpp 
main.cpp)
-target_link_libraries(test-prison Qt${QT_MAJOR_VERSION}::Widgets KF5::Prison)
+add_executable(prison-test)
+target_sources(prison-test PRIVATE prisontest.cpp barcodeexamplewidget.cpp 
main.cpp)
+target_link_libraries(prison-test Qt${QT_MAJOR_VERSION}::Widgets KF5::Prison)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/barcodeexamplewidget.cpp 
new/prison-5.95.0/tests/barcodeexamplewidget.cpp
--- old/prison-5.94.0/tests/barcodeexamplewidget.cpp    2022-05-06 
13:22:05.000000000 +0200
+++ new/prison-5.95.0/tests/barcodeexamplewidget.cpp    2022-06-04 
10:25:17.000000000 +0200
@@ -6,7 +6,7 @@
 
 #include "barcodeexamplewidget.h"
 // Prison
-#include <prison/abstractbarcode.h>
+#include <Prison/AbstractBarcode>
 // Qt
 #include <QDrag>
 #include <QGuiApplication>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/main.cpp 
new/prison-5.95.0/tests/main.cpp
--- old/prison-5.94.0/tests/main.cpp    2022-05-06 13:22:05.000000000 +0200
+++ new/prison-5.95.0/tests/main.cpp    2022-06-04 10:25:17.000000000 +0200
@@ -1,4 +1,4 @@
-#include "prison.h"
+#include "prisontest.h"
 #include <QApplication>
 
 int main(int argc, char **argv)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/prison.cpp 
new/prison-5.95.0/tests/prison.cpp
--- old/prison-5.94.0/tests/prison.cpp  2022-05-06 13:22:05.000000000 +0200
+++ new/prison-5.95.0/tests/prison.cpp  1970-01-01 01:00:00.000000000 +0100
@@ -1,132 +0,0 @@
-/*
-    SPDX-FileCopyrightText: 2010-2016 Sune Vuorela <s...@vuorela.dk>
-
-    SPDX-License-Identifier: MIT
-*/
-
-#include "prison.h"
-
-#include "barcodeexamplewidget.h"
-// Prison
-#include <prison/abstractbarcode.h>
-#include <prison/prison.h>
-// Qt
-#include <QDebug>
-#include <QHBoxLayout>
-#include <QLineEdit>
-#include <QPushButton>
-#include <QSplitter>
-
-void main_window::data_changed()
-{
-    QString result = m_lineedit->text();
-    m_dmw->setData(result);
-    m_qrw->setData(result);
-    m_39w->setData(result);
-    m_93w->setData(result);
-    m_nullw->setData(result);
-    m_dmcolor->setData(result);
-    m_qrcolor->setData(result);
-    m_39color->setData(result);
-    m_93color->setData(result);
-}
-
-main_window::main_window()
-{
-    QHBoxLayout *lay = new QHBoxLayout();
-    m_lineedit = new QLineEdit(this);
-    QPushButton *but = new QPushButton(this);
-    connect(but, &QPushButton::clicked, this, &main_window::data_changed);
-    lay->addWidget(m_lineedit);
-    lay->addWidget(but);
-
-    QVBoxLayout *mainlay = new QVBoxLayout(this);
-
-    {
-        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::DataMatrix);
-        if (!barcode) {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_dmw = new BarcodeExampleWidget(barcode, this);
-    }
-    {
-        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::QRCode);
-        if (!barcode) {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_qrw = new BarcodeExampleWidget(barcode, this);
-    }
-    {
-        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::Code39);
-        if (!barcode) {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_39w = new BarcodeExampleWidget(barcode, this);
-    }
-    {
-        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::Code93);
-        if (!barcode) {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_93w = new BarcodeExampleWidget(barcode, this);
-    }
-    {
-        Prison::AbstractBarcode *dmcolorcode = 
Prison::createBarcode(Prison::DataMatrix);
-        if (dmcolorcode) {
-            dmcolorcode->setForegroundColor(Qt::red);
-            dmcolorcode->setBackgroundColor(Qt::darkBlue);
-        } else {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_dmcolor = new BarcodeExampleWidget(dmcolorcode, this);
-    }
-    {
-        Prison::AbstractBarcode *qrcolorcode = 
Prison::createBarcode(Prison::QRCode);
-        if (qrcolorcode) {
-            qrcolorcode->setForegroundColor(Qt::red);
-            qrcolorcode->setBackgroundColor(Qt::darkBlue);
-        } else {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_qrcolor = new BarcodeExampleWidget(qrcolorcode, this);
-    }
-    {
-        Prison::AbstractBarcode *c39colorcode = 
Prison::createBarcode(Prison::Code39);
-        if (c39colorcode) {
-            c39colorcode->setForegroundColor(Qt::red);
-            c39colorcode->setBackgroundColor(Qt::darkBlue);
-        } else {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_39color = new BarcodeExampleWidget(c39colorcode, this);
-    }
-    {
-        Prison::AbstractBarcode *c93colorcode = 
Prison::createBarcode(Prison::Code93);
-        if (c93colorcode) {
-            c93colorcode->setForegroundColor(Qt::red);
-            c93colorcode->setBackgroundColor(Qt::darkBlue);
-        } else {
-            qDebug() << "unsupported barcode, showing a black square";
-        }
-        m_93color = new BarcodeExampleWidget(c93colorcode, this);
-    }
-
-    m_nullw = new BarcodeExampleWidget(nullptr, this);
-
-    QSplitter *splitter = new QSplitter(Qt::Vertical);
-    splitter->addWidget(m_dmw);
-    splitter->addWidget(m_qrw);
-    splitter->addWidget(m_39w);
-    splitter->addWidget(m_93w);
-    splitter->addWidget(m_dmcolor);
-    splitter->addWidget(m_qrcolor);
-    splitter->addWidget(m_39color);
-    splitter->addWidget(m_93color);
-    splitter->addWidget(m_nullw);
-
-    mainlay->addLayout(lay);
-    mainlay->addWidget(splitter);
-
-    m_lineedit->setText(QStringLiteral("AOEUIAOEUIAOEUI"));
-    data_changed();
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/prison.h 
new/prison-5.95.0/tests/prison.h
--- old/prison-5.94.0/tests/prison.h    2022-05-06 13:22:05.000000000 +0200
+++ new/prison-5.95.0/tests/prison.h    1970-01-01 01:00:00.000000000 +0100
@@ -1,30 +0,0 @@
-#ifndef prison_H
-#define prison_H
-
-#include <QWidget>
-
-class BarcodeExampleWidget;
-
-class QLineEdit;
-class main_window : public QWidget
-{
-    Q_OBJECT
-public:
-    main_window();
-public Q_SLOTS:
-    void data_changed();
-
-private:
-    QLineEdit *m_lineedit = nullptr;
-    BarcodeExampleWidget *m_dmw = nullptr;
-    BarcodeExampleWidget *m_qrw = nullptr;
-    BarcodeExampleWidget *m_39w = nullptr;
-    BarcodeExampleWidget *m_93w = nullptr;
-    BarcodeExampleWidget *m_dmcolor = nullptr;
-    BarcodeExampleWidget *m_qrcolor = nullptr;
-    BarcodeExampleWidget *m_39color = nullptr;
-    BarcodeExampleWidget *m_93color = nullptr;
-    BarcodeExampleWidget *m_nullw = nullptr;
-};
-
-#endif // prison_H
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/prisontest.cpp 
new/prison-5.95.0/tests/prisontest.cpp
--- old/prison-5.94.0/tests/prisontest.cpp      1970-01-01 01:00:00.000000000 
+0100
+++ new/prison-5.95.0/tests/prisontest.cpp      2022-06-04 10:25:17.000000000 
+0200
@@ -0,0 +1,132 @@
+/*
+    SPDX-FileCopyrightText: 2010-2016 Sune Vuorela <s...@vuorela.dk>
+
+    SPDX-License-Identifier: MIT
+*/
+
+#include "prisontest.h"
+
+#include "barcodeexamplewidget.h"
+// Prison
+#include <Prison/AbstractBarcode>
+#include <Prison/Prison>
+// Qt
+#include <QDebug>
+#include <QHBoxLayout>
+#include <QLineEdit>
+#include <QPushButton>
+#include <QSplitter>
+
+void main_window::data_changed()
+{
+    QString result = m_lineedit->text();
+    m_dmw->setData(result);
+    m_qrw->setData(result);
+    m_39w->setData(result);
+    m_93w->setData(result);
+    m_nullw->setData(result);
+    m_dmcolor->setData(result);
+    m_qrcolor->setData(result);
+    m_39color->setData(result);
+    m_93color->setData(result);
+}
+
+main_window::main_window()
+{
+    QHBoxLayout *lay = new QHBoxLayout();
+    m_lineedit = new QLineEdit(this);
+    QPushButton *but = new QPushButton(this);
+    connect(but, &QPushButton::clicked, this, &main_window::data_changed);
+    lay->addWidget(m_lineedit);
+    lay->addWidget(but);
+
+    QVBoxLayout *mainlay = new QVBoxLayout(this);
+
+    {
+        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::DataMatrix);
+        if (!barcode) {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_dmw = new BarcodeExampleWidget(barcode, this);
+    }
+    {
+        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::QRCode);
+        if (!barcode) {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_qrw = new BarcodeExampleWidget(barcode, this);
+    }
+    {
+        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::Code39);
+        if (!barcode) {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_39w = new BarcodeExampleWidget(barcode, this);
+    }
+    {
+        Prison::AbstractBarcode *barcode = 
Prison::createBarcode(Prison::Code93);
+        if (!barcode) {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_93w = new BarcodeExampleWidget(barcode, this);
+    }
+    {
+        Prison::AbstractBarcode *dmcolorcode = 
Prison::createBarcode(Prison::DataMatrix);
+        if (dmcolorcode) {
+            dmcolorcode->setForegroundColor(Qt::red);
+            dmcolorcode->setBackgroundColor(Qt::darkBlue);
+        } else {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_dmcolor = new BarcodeExampleWidget(dmcolorcode, this);
+    }
+    {
+        Prison::AbstractBarcode *qrcolorcode = 
Prison::createBarcode(Prison::QRCode);
+        if (qrcolorcode) {
+            qrcolorcode->setForegroundColor(Qt::red);
+            qrcolorcode->setBackgroundColor(Qt::darkBlue);
+        } else {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_qrcolor = new BarcodeExampleWidget(qrcolorcode, this);
+    }
+    {
+        Prison::AbstractBarcode *c39colorcode = 
Prison::createBarcode(Prison::Code39);
+        if (c39colorcode) {
+            c39colorcode->setForegroundColor(Qt::red);
+            c39colorcode->setBackgroundColor(Qt::darkBlue);
+        } else {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_39color = new BarcodeExampleWidget(c39colorcode, this);
+    }
+    {
+        Prison::AbstractBarcode *c93colorcode = 
Prison::createBarcode(Prison::Code93);
+        if (c93colorcode) {
+            c93colorcode->setForegroundColor(Qt::red);
+            c93colorcode->setBackgroundColor(Qt::darkBlue);
+        } else {
+            qDebug() << "unsupported barcode, showing a black square";
+        }
+        m_93color = new BarcodeExampleWidget(c93colorcode, this);
+    }
+
+    m_nullw = new BarcodeExampleWidget(nullptr, this);
+
+    QSplitter *splitter = new QSplitter(Qt::Vertical);
+    splitter->addWidget(m_dmw);
+    splitter->addWidget(m_qrw);
+    splitter->addWidget(m_39w);
+    splitter->addWidget(m_93w);
+    splitter->addWidget(m_dmcolor);
+    splitter->addWidget(m_qrcolor);
+    splitter->addWidget(m_39color);
+    splitter->addWidget(m_93color);
+    splitter->addWidget(m_nullw);
+
+    mainlay->addLayout(lay);
+    mainlay->addWidget(splitter);
+
+    m_lineedit->setText(QStringLiteral("AOEUIAOEUIAOEUI"));
+    data_changed();
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/prison-5.94.0/tests/prisontest.h 
new/prison-5.95.0/tests/prisontest.h
--- old/prison-5.94.0/tests/prisontest.h        1970-01-01 01:00:00.000000000 
+0100
+++ new/prison-5.95.0/tests/prisontest.h        2022-06-04 10:25:17.000000000 
+0200
@@ -0,0 +1,30 @@
+#ifndef prison_H
+#define prison_H
+
+#include <QWidget>
+
+class BarcodeExampleWidget;
+
+class QLineEdit;
+class main_window : public QWidget
+{
+    Q_OBJECT
+public:
+    main_window();
+public Q_SLOTS:
+    void data_changed();
+
+private:
+    QLineEdit *m_lineedit = nullptr;
+    BarcodeExampleWidget *m_dmw = nullptr;
+    BarcodeExampleWidget *m_qrw = nullptr;
+    BarcodeExampleWidget *m_39w = nullptr;
+    BarcodeExampleWidget *m_93w = nullptr;
+    BarcodeExampleWidget *m_dmcolor = nullptr;
+    BarcodeExampleWidget *m_qrcolor = nullptr;
+    BarcodeExampleWidget *m_39color = nullptr;
+    BarcodeExampleWidget *m_93color = nullptr;
+    BarcodeExampleWidget *m_nullw = nullptr;
+};
+
+#endif // prison_H

Reply via email to