From 2215b648f07e396c6f54b99937ad45a5861a22ae Mon Sep 17 00:00:00 2001 From: Harald Oehlmann Date: Tue, 18 Aug 2015 14:56:55 +0200 Subject: [PATCH] Added possibility to not use Datamatrix rectangular extensions --- backend/dmatrix.h | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/backend/dmatrix.h b/backend/dmatrix.h index db1fb28f..a9b8cef1 100644 --- a/backend/dmatrix.h +++ b/backend/dmatrix.h @@ -84,6 +84,11 @@ static const int text_value[] = { 15,16,17,18,19,20,21,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26, 22,23,24,25,26,0,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,27,28,29,30,31 }; +// Activate DMRE Extensions +//#define DMRE +#ifdef DMRE +// With Rectangular extensions + // Position in option array [symbol option value - 1] // The position in the option array is by increasing total data codewords with square first @@ -218,4 +223,45 @@ static const int matrixrsblock[] = { /*40*/ 62, /*132x132*/ 62 /*144x144*/ }; +#else +// No Rectangular extensions + +static const int intsymbol[] = { + 0,1,3,5,7,8,10,12,13,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,2,4,6,9,11,14 }; + +// Number of DM Sizes +#define DMSIZESCOUNT 30 +// Number of 144x144 for special interlace +#define INTSYMBOL144 29 + +static const int matrixH[] = { + 10, 12, 8, 14, 8, 16, 12, 18, 20, 12, 22, 16, 24, 26, 16, 32, 36, 40, 44, 48, + 52, 64, 72, 80, 88, 96, 104, 120, 132, 144 }; + +static const int matrixW[] = { + 10, 12, 18, 14, 32, 16, 26, 18, 20, 36, 22, 36, 24, 26, 48, 32, 36, 40, 44, + 48, 52, 64, 72, 80, 88, 96, 104, 120, 132, 144 }; + +static const int matrixFH[] = { + 10, 12, 8, 14, 8, 16, 12, 18, 20, 12, 22, 16, 24, 26, 16, 16, 18, 20, 22, 24, + 26, 16, 18, 20, 22, 24, 26, 20, 22, 24 }; + +static const int matrixFW[] = { + 10, 12, 18, 14, 16, 16, 26, 18, 20, 18, 22, 18, 24, 26, 24, 16, 18, 20, 22, + 24, 26, 16, 18, 20, 22, 24, 26, 20, 22, 24 }; + +static const int matrixbytes[] = { + 3, 5, 5, 8, 10, 12, 16, 18, 22, 22, 30, 32, 36, 44, 49, 62, 86, 114, 144, + 174, 204, 280, 368, 456, 576, 696, 816, 1050, 1304, 1558 }; + +static const int matrixdatablock[] = { + 3, 5, 5, 8, 10, 12, 16, 18, 22, 22, 30, 32, 36, 44, 49, 62, 86, 114, 144, + 174, 102, 140, 92, 114, 144, 174, 136, 175, 163, 156 }; + +static const int matrixrsblock[] = { + 5, 7, 7, 10, 11, 12, 14, 14, 18, 18, 20, 24, 24, 28, 28, 36, 42, 48, 56, 68, + 42, 56, 36, 48, 56, 68, 56, 68, 62, 62 }; + +#endif + #endif /* __IEC16022ECC200_H */