comparison mupdf-source/thirdparty/zxing-cpp/wrappers/winrt/BarcodeReader.h @ 2:b50eed0cc0ef upstream

ADD: MuPDF v1.26.7: the MuPDF source as downloaded by a default build of PyMuPDF 1.26.4. The directory name has changed: no version number in the expanded directory now.
author Franz Glasner <fzglas.hg@dom66.de>
date Mon, 15 Sep 2025 11:43:07 +0200
parents
children
comparison
equal deleted inserted replaced
1:1d09e1dec1d9 2:b50eed0cc0ef
1 /*
2 * Copyright 2016 Nu-book Inc.
3 */
4 // SPDX-License-Identifier: Apache-2.0
5
6 #pragma once
7
8 #include "BarcodeFormat.h"
9 #include "ReaderOptions.h"
10
11 #include <memory>
12
13 namespace ZXing {
14
15 public enum class BarcodeType : int {
16 AZTEC,
17 CODABAR,
18 CODE_39,
19 CODE_93,
20 CODE_128,
21 DATA_MATRIX,
22 DX_FILM_EDGE,
23 EAN_8,
24 EAN_13,
25 ITF,
26 MAXICODE,
27 PDF_417,
28 QR_CODE,
29 MICRO_QR_CODE,
30 RMQR_CODE,
31 RSS_14,
32 RSS_EXPANDED,
33 DATA_BAR_LIMITED,
34 UPC_A,
35 UPC_E
36 };
37
38 ref class ReadResult;
39
40 public ref class BarcodeReader sealed
41 {
42 public:
43 BarcodeReader(bool tryHarder, bool tryRotate, const Platform::Array<BarcodeType>^ types);
44 BarcodeReader(bool tryHarder, bool tryRotate);
45 BarcodeReader(bool tryHarder);
46
47 ReadResult^ Read(Windows::Graphics::Imaging::SoftwareBitmap^ bitmap, int cropWidth, int cropHeight);
48
49 private:
50 ~BarcodeReader();
51
52 void init(bool tryHarder, bool tryRotate, const Platform::Array<BarcodeType>^ types);
53
54 static BarcodeFormat ConvertRuntimeToNative(BarcodeType type);
55 static BarcodeType ConvertNativeToRuntime(BarcodeFormat format);
56
57 std::unique_ptr<ReaderOptions> m_opts;
58 };
59
60 } // ZXing