OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #ifndef XFA_FXBARCODE_DATAMATRIX_BC_DATAMATRIXBITMATRIXPARSER_H_ | 7 #ifndef XFA_FXBARCODE_DATAMATRIX_BC_DATAMATRIXBITMATRIXPARSER_H_ |
8 #define XFA_FXBARCODE_DATAMATRIX_BC_DATAMATRIXBITMATRIXPARSER_H_ | 8 #define XFA_FXBARCODE_DATAMATRIX_BC_DATAMATRIXBITMATRIXPARSER_H_ |
9 | 9 |
10 #include "core/fxcrt/include/fx_basic.h" | 10 #include "core/fxcrt/include/fx_basic.h" |
11 | 11 |
12 class CBC_CommonBitMatrix; | 12 class CBC_CommonBitMatrix; |
13 class CBC_DataMatrixVersion; | 13 class CBC_DataMatrixVersion; |
14 | 14 |
15 class CBC_DataMatrixBitMatrixParser { | 15 class CBC_DataMatrixBitMatrixParser { |
16 public: | 16 public: |
17 CBC_DataMatrixBitMatrixParser(); | 17 CBC_DataMatrixBitMatrixParser(); |
18 virtual ~CBC_DataMatrixBitMatrixParser(); | 18 virtual ~CBC_DataMatrixBitMatrixParser(); |
| 19 |
19 CBC_DataMatrixVersion* GetVersion(); | 20 CBC_DataMatrixVersion* GetVersion(); |
20 CFX_ByteArray* ReadCodewords(int32_t& e); | 21 CFX_ByteArray* ReadCodewords(int32_t& e); |
21 FX_BOOL ReadModule(int32_t row, | 22 FX_BOOL ReadModule(int32_t row, |
22 int32_t column, | 23 int32_t column, |
23 int32_t numRows, | 24 int32_t numRows, |
24 int32_t numColumns); | 25 int32_t numColumns); |
25 int32_t ReadUtah(int32_t row, | 26 int32_t ReadUtah(int32_t row, |
26 int32_t column, | 27 int32_t column, |
27 int32_t numRows, | 28 int32_t numRows, |
28 int32_t numColumns); | 29 int32_t numColumns); |
29 int32_t ReadCorner1(int32_t numRows, int32_t numColumns); | 30 int32_t ReadCorner1(int32_t numRows, int32_t numColumns); |
30 int32_t ReadCorner2(int32_t numRows, int32_t numColumns); | 31 int32_t ReadCorner2(int32_t numRows, int32_t numColumns); |
31 int32_t ReadCorner3(int32_t numRows, int32_t numColumns); | 32 int32_t ReadCorner3(int32_t numRows, int32_t numColumns); |
32 int32_t ReadCorner4(int32_t numRows, int32_t numColumns); | 33 int32_t ReadCorner4(int32_t numRows, int32_t numColumns); |
33 CBC_CommonBitMatrix* ExtractDataRegion(CBC_CommonBitMatrix* bitMatrix, | 34 CBC_CommonBitMatrix* ExtractDataRegion(CBC_CommonBitMatrix* bitMatrix, |
34 int32_t& e); | 35 int32_t& e); |
35 virtual void Init(CBC_CommonBitMatrix* bitMatrix, int32_t& e); | 36 virtual void Init(CBC_CommonBitMatrix* bitMatrix, int32_t& e); |
36 | 37 |
37 private: | 38 private: |
38 static CBC_DataMatrixVersion* ReadVersion(CBC_CommonBitMatrix* bitMatrix, | 39 static CBC_DataMatrixVersion* ReadVersion(CBC_CommonBitMatrix* bitMatrix, |
39 int32_t& e); | 40 int32_t& e); |
40 CBC_CommonBitMatrix* m_mappingBitMatrix; | 41 CBC_CommonBitMatrix* m_mappingBitMatrix; |
41 CBC_CommonBitMatrix* m_readMappingMatrix; | 42 CBC_CommonBitMatrix* m_readMappingMatrix; |
42 CBC_DataMatrixVersion* m_version; | 43 CBC_DataMatrixVersion* m_version; |
43 }; | 44 }; |
44 | 45 |
45 #endif // XFA_FXBARCODE_DATAMATRIX_BC_DATAMATRIXBITMATRIXPARSER_H_ | 46 #endif // XFA_FXBARCODE_DATAMATRIX_BC_DATAMATRIXBITMATRIXPARSER_H_ |
OLD | NEW |