zxing: update to 1.4.0 tag
authorStéphane Cerveau <scerveau@igalia.com>
Tue, 22 Nov 2022 11:32:52 +0000 (12:32 +0100)
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Sun, 11 Dec 2022 15:52:08 +0000 (15:52 +0000)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3450>

subprojects/gst-plugins-bad/ext/zxing/gstzxing.cpp
subprojects/gst-plugins-bad/ext/zxing/meson.build

index 5f296ec..7836dbb 100644 (file)
@@ -368,7 +368,7 @@ gst_zxing_transform_frame_ip (GstVideoFilter * vfilter, GstVideoFrame * frame)
   auto result = ReadBarcode ({(unsigned char *)data, width, height, zxing->image_format}, hints);
   if (result.isValid ()) {
     GST_DEBUG_OBJECT (zxing, "Symbol found. Text: %s Format: %s",
-        TextUtfEncoding::ToUtf8 (result.text ()).c_str (),
+        result.text ().c_str (),
         ToString (result.format ()));
   } else {
     goto out;
@@ -396,7 +396,7 @@ gst_zxing_transform_frame_ip (GstVideoFilter * vfilter, GstVideoFrame * frame)
         "running-time", G_TYPE_UINT64, running_time,
         "type", G_TYPE_STRING, ToString (result.format ()),
         "symbol", G_TYPE_STRING,
-        TextUtfEncoding::ToUtf8 (result.text ()).c_str (), NULL);
+        result.text ().c_str (), NULL);
 
     if (zxing->attach_frame) {
       /* create a sample from image */
index 5992f0d..2dbad9a 100644 (file)
@@ -2,16 +2,17 @@ zxing_sources = [
   'gstzxing.cpp',
   'gstzxingplugin.c',
 ]
-zxing_dep = dependency('zxing', version : '>= 1.1.1', required : get_option('zxing'))
+zxing_dep = dependency('zxing', version : '>= 1.4.0', required : get_option('zxing'))
 if zxing_dep.found()
        gstzxing = library('gstzxing',
          zxing_sources,
          c_args : gst_plugins_bad_args,
+         cpp_args: '-DZX_USE_UTF8',
          include_directories : [configinc],
          dependencies : [gstvideo_dep, zxing_dep],
          install : true,
          install_dir : plugins_install_dir,
-          override_options : ['cpp_std=c++11'],
+         override_options : ['cpp_std=c++17'],
        )
        plugins += [gstzxing]
 endif