Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- typedef char CHAR;
- typedef unsigned char UCHAR;
- typedef short SHORT;
- typedef unsigned short USHORT;
- typedef int INT;
- typedef unsigned int UINT;
- public struct tByte
- {
- UCHAR HiNibble : 4;
- UCHAR LoNibble : 4;
- };
- public struct WindowMatchInfo{
- USHORT Length : 3;
- USHORT Offset : 13;
- };
- public struct WindowMatch{
- var LastExtraByteHighNibble = 0;
- WindowMatchInfo WindowInfo;
- if (WindowInfo.Length >= 7){
- bExtraByteToggle = (!bExtraByteToggle);
- if (bExtraByteToggle){
- tByte ExtraLenByte;
- bExtraByteHighNibble = ExtraLenByte.HiNibble;
- if (ExtraLenByte.LoNibble >= 15){
- UCHAR AddByte1;
- if (AddByte1 >= 255){
- USHORT WholeByteLen1;
- }
- }
- }else{
- if (bExtraByteHighNibble >= 15){
- UCHAR AddByte2;
- if (AddByte2 >= 255){
- USHORT WholeByteLen2;
- }
- }
- }
- }
- };
- public struct MetaMap{
- UCHAR Bit0 : 1;
- UCHAR Bit1 : 1;
- UCHAR Bit2 : 1;
- UCHAR Bit3 : 1;
- UCHAR Bit4 : 1;
- UCHAR Bit5 : 1;
- UCHAR Bit6 : 1;
- UCHAR Bit7 : 1;
- UCHAR Bit8 : 1;
- UCHAR Bit9 : 1;
- UCHAR Bit10 : 1;
- UCHAR Bit11 : 1;
- UCHAR Bit12: 1;
- UCHAR Bit13: 1;
- UCHAR Bit14 : 1;
- UCHAR Bit15 : 1;
- UCHAR Bit16 : 1;
- UCHAR Bit17 : 1;
- UCHAR Bit18 : 1;
- UCHAR Bit19 : 1;
- UCHAR Bit20 : 1;
- UCHAR Bit21 : 1;
- UCHAR Bit22 : 1;
- UCHAR Bit23 : 1;
- UCHAR Bit24 : 1;
- UCHAR Bit25 : 1;
- UCHAR Bit26 : 1;
- UCHAR Bit27 : 1;
- UCHAR Bit28 : 1;
- UCHAR Bit29 : 1;
- UCHAR Bit30 : 1;
- UCHAR Bit31 : 1;
- };
- public struct LZ77{
- var bExtraByteToggle=0;
- var bExtraByteHighNibble= 0;
- MetaMap Map;
- if (Map.Bit31){
- WindowMatch Match31;
- }else{
- char Byte31;
- }
- if (Map.Bit30){
- WindowMatch Match30;
- }else{
- char Byte30;
- }
- if (Map.Bit29){
- WindowMatch Match29;
- }else{
- char Byte29;
- }
- if (Map.Bit28){
- WindowMatch Match28;
- }else{
- char Byte28;
- }
- if (Map.Bit27){
- WindowMatch Match27;
- }else{
- char Byte27;
- }
- if (Map.Bit26){
- WindowMatch Match26;
- }else{
- char Byte26;
- }
- if (Map.Bit25){
- WindowMatch Match25;
- }else{
- char Byte25;
- }
- if (Map.Bit24){
- WindowMatch Match24;
- }else{
- char Byte24;
- }
- if (Map.Bit23){
- WindowMatch Match23;
- }else{
- char Byte23;
- }
- if (Map.Bit22){
- WindowMatch Match22;
- }else{
- char Byte22;
- }
- if (Map.Bit21){
- WindowMatch Match21;
- }else{
- char Byte21;
- }
- if (Map.Bit20){
- WindowMatch Match20;
- }else{
- char Byte20;
- }
- if (Map.Bit19){
- WindowMatch Match19;
- }else{
- char Byte19;
- }
- if (Map.Bit18){
- WindowMatch Match18;
- }else{
- char Byte18;
- }
- if (Map.Bit17){
- WindowMatch Match17;
- }else{
- char Byte17;
- }
- if (Map.Bit16){
- WindowMatch Match16;
- }else{
- char Byte16;
- }
- if (Map.Bit15){
- WindowMatch Match15;
- }else{
- char Byte15;
- }
- if (Map.Bit14){
- WindowMatch Match14;
- }else{
- char Byte14;
- }
- if (Map.Bit13){
- WindowMatch Match13;
- }else{
- char Byte13;
- }
- if (Map.Bit12){
- WindowMatch Match12;
- }else{
- char Byte12;
- }
- if (Map.Bit11){
- WindowMatch Match11;
- }else{
- char Byte11;
- }
- if (Map.Bit10){
- WindowMatch Match10;
- }else{
- char Byte10;
- }
- if (Map.Bit9){
- WindowMatch Match9;
- }else{
- char Byte9;
- }
- if (Map.Bit8){
- WindowMatch Match8;
- }else{
- char Byte8;
- }
- if (Map.Bit7){
- WindowMatch Match7;
- }else{
- char Byte7;
- }
- if (Map.Bit6){
- WindowMatch Match6;
- }else{
- char Byte6;
- }
- if (Map.Bit5){
- WindowMatch Match5;
- }else{
- char Byte5;
- }
- if (Map.Bit4){
- WindowMatch Match4;
- }else{
- char Byte4;
- }
- if (Map.Bit3){
- WindowMatch Match3;
- }else{
- char Byte3;
- }
- if (Map.Bit2){
- WindowMatch Match2;
- }else{
- char Byte2;
- }
- if (Map.Bit1){
- WindowMatch Match1;
- }else{
- char Byte1;
- }
- if (Map.Bit0){
- WindowMatch Match0;
- }else{
- char Byte0;
- }
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement