Mercurial > vba-linux
comparison src/win32/7zip/7z/CPP/7zip/Compress/BitlDecoder.cpp @ 1:f9f4f1b99eed
importing src directory
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Sat, 03 Mar 2012 10:31:27 -0600 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
0:8ced16adf2e1 | 1:f9f4f1b99eed |
---|---|
1 // BitlDecoder.cpp | |
2 | |
3 #include "StdAfx.h" | |
4 | |
5 #include "BitlDecoder.h" | |
6 | |
7 namespace NBitl { | |
8 | |
9 Byte kInvertTable[256]; | |
10 | |
11 struct CInverterTableInitializer | |
12 { | |
13 CInverterTableInitializer() | |
14 { | |
15 for (int i = 0; i < 256; i++) | |
16 { | |
17 int x = ((i & 0x55) << 1) | ((i & 0xAA) >> 1); | |
18 x = ((x & 0x33) << 2) | ((x & 0xCC) >> 2); | |
19 kInvertTable[i] = (Byte)(((x & 0x0F) << 4) | ((x & 0xF0) >> 4)); | |
20 } | |
21 } | |
22 } g_InverterTableInitializer; | |
23 | |
24 } |