| 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 _BC_SYMBOLINFO_H_ | 7 #ifndef _BC_SYMBOLINFO_H_ |
| 8 #define _BC_SYMBOLINFO_H_ | 8 #define _BC_SYMBOLINFO_H_ |
| 9 class CBC_SymbolShapeHint; | 9 class CBC_SymbolShapeHint; |
| 10 class CBC_Dimension; | 10 class CBC_Dimension; |
| 11 class CBC_SymbolInfo; | 11 class CBC_SymbolInfo; |
| 12 class CBC_SymbolInfo : public CBC_SymbolShapeHint | 12 class CBC_SymbolInfo : public CBC_SymbolShapeHint |
| 13 { | 13 { |
| 14 public: | 14 public: |
| 15 CBC_SymbolInfo(FX_BOOL rectangular, FX_INT32 dataCapacity, FX_INT32 errorCod
ewords, | 15 CBC_SymbolInfo(FX_BOOL rectangular, int32_t dataCapacity, int32_t errorCodew
ords, |
| 16 FX_INT32 matrixWidth, FX_INT32 matrixHeight, FX_INT32 dataReg
ions); | 16 int32_t matrixWidth, int32_t matrixHeight, int32_t dataRegion
s); |
| 17 virtual ~CBC_SymbolInfo(); | 17 virtual ~CBC_SymbolInfo(); |
| 18 static void Initialize(); | 18 static void Initialize(); |
| 19 static void Finalize(); | 19 static void Finalize(); |
| 20 static void overrideSymbolSet(CBC_SymbolInfo* override); | 20 static void overrideSymbolSet(CBC_SymbolInfo* override); |
| 21 static CBC_SymbolInfo* lookup(FX_INT32 dataCodewords, FX_INT32 &e); | 21 static CBC_SymbolInfo* lookup(int32_t dataCodewords, int32_t &e); |
| 22 static CBC_SymbolInfo* lookup(FX_INT32 dataCodewords, SymbolShapeHint shape,
FX_INT32 &e); | 22 static CBC_SymbolInfo* lookup(int32_t dataCodewords, SymbolShapeHint shape,
int32_t &e); |
| 23 static CBC_SymbolInfo* lookup(FX_INT32 dataCodewords, FX_BOOL allowRectangul
ar, FX_BOOL fail, FX_INT32 &e); | 23 static CBC_SymbolInfo* lookup(int32_t dataCodewords, FX_BOOL allowRectangula
r, FX_BOOL fail, int32_t &e); |
| 24 static CBC_SymbolInfo* lookup(FX_INT32 dataCodewords, SymbolShapeHint shape,
FX_BOOL fail, FX_INT32 &e); | 24 static CBC_SymbolInfo* lookup(int32_t dataCodewords, SymbolShapeHint shape,
FX_BOOL fail, int32_t &e); |
| 25 static CBC_SymbolInfo* lookup(FX_INT32 dataCodewords, SymbolShapeHint shape,
CBC_Dimension* minSize, CBC_Dimension* maxSize, FX_BOOL fail, FX_INT32 &e); | 25 static CBC_SymbolInfo* lookup(int32_t dataCodewords, SymbolShapeHint shape,
CBC_Dimension* minSize, CBC_Dimension* maxSize, FX_BOOL fail, int32_t &e); |
| 26 FX_INT32 getHorizontalDataRegions(FX_INT32 &e); | 26 int32_t getHorizontalDataRegions(int32_t &e); |
| 27 FX_INT32 getVerticalDataRegions(FX_INT32 &e); | 27 int32_t getVerticalDataRegions(int32_t &e); |
| 28 FX_INT32 getSymbolDataWidth(FX_INT32 &e); | 28 int32_t getSymbolDataWidth(int32_t &e); |
| 29 FX_INT32 getSymbolDataHeight(FX_INT32 &e); | 29 int32_t getSymbolDataHeight(int32_t &e); |
| 30 FX_INT32 getSymbolWidth(FX_INT32 &e); | 30 int32_t getSymbolWidth(int32_t &e); |
| 31 FX_INT32 getSymbolHeight(FX_INT32 &e); | 31 int32_t getSymbolHeight(int32_t &e); |
| 32 FX_INT32 getCodewordCount(); | 32 int32_t getCodewordCount(); |
| 33 FX_INT32 getInterleavedBlockCount(); | 33 int32_t getInterleavedBlockCount(); |
| 34 FX_INT32 getDataLengthForInterleavedBlock(FX_INT32 index); | 34 int32_t getDataLengthForInterleavedBlock(int32_t index); |
| 35 FX_INT32 getErrorLengthForInterleavedBlock(FX_INT32 index); | 35 int32_t getErrorLengthForInterleavedBlock(int32_t index); |
| 36 CFX_WideString toString(FX_INT32 &e); | 36 CFX_WideString toString(int32_t &e); |
| 37 public: | 37 public: |
| 38 FX_INT32 m_dataCapacity; | 38 int32_t m_dataCapacity; |
| 39 FX_INT32 m_errorCodewords; | 39 int32_t m_errorCodewords; |
| 40 FX_INT32 m_matrixWidth; | 40 int32_t m_matrixWidth; |
| 41 FX_INT32 m_matrixHeight; | 41 int32_t m_matrixHeight; |
| 42 FX_INT32 m_rsBlockData; | 42 int32_t m_rsBlockData; |
| 43 FX_INT32 m_rsBlockError; | 43 int32_t m_rsBlockError; |
| 44 static CBC_SymbolInfo* m_PROD_SYMBOLS[30]; | 44 static CBC_SymbolInfo* m_PROD_SYMBOLS[30]; |
| 45 private: | 45 private: |
| 46 static CBC_SymbolInfo* m_symbols[30]; | 46 static CBC_SymbolInfo* m_symbols[30]; |
| 47 FX_BOOL m_rectangular; | 47 FX_BOOL m_rectangular; |
| 48 FX_INT32 m_dataRegions; | 48 int32_t m_dataRegions; |
| 49 private: | 49 private: |
| 50 CBC_SymbolInfo(FX_BOOL rectangular, FX_INT32 dataCapacity, FX_INT32 errorCod
ewords, FX_INT32 matrixWidth, FX_INT32 matrixHeight, FX_INT32 dataRegions, | 50 CBC_SymbolInfo(FX_BOOL rectangular, int32_t dataCapacity, int32_t errorCodew
ords, int32_t matrixWidth, int32_t matrixHeight, int32_t dataRegions, |
| 51 FX_INT32 rsBlockData, FX_INT32 rsBlockError); | 51 int32_t rsBlockData, int32_t rsBlockError); |
| 52 }; | 52 }; |
| 53 #endif | 53 #endif |
| OLD | NEW |