亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? comp_groupsmart.bas

?? 里面有二十一種加密的算法,很好用的哦,大家一定要多多下載啊
?? BAS
?? 第 1 頁 / 共 2 頁
字號:
Attribute VB_Name = "Comp_GroupSmart"


Option Explicit

'This is a 1 run method

'This method is the smartgrouping method
'it will search for follower bytes within a curtain range wich
'will fit into a curtain bitlenght
'It will search as long as needed to find the best compression
'if it finds followers of 12*0 and 4*1 = 16 bytes it will be compressed
'because 0 - 0 and 1 - 0 will both fit into 1 bit, it will fit
'in 16*1 bit wich will lead to to the following
'in 17 headerbits and 16 codebits = 33 bits = 4 bytes and 1 bit
'if it finds followers of 12*0 and 4*173 = 16 bytes it will be compressed
'because 0 - 0 will fit in 1 bit and 173 - 173 will fit into 1 bit it will fit
'in 12*1 bit and 4*1 bit wich will lead to to the following
'in 17 headerbits and 12 codebits = 29 bits = 3 bytes and 5 bits
'in 17 headerbits and 4 codebits = 21 bits = 2 bytes and 3 bits
'wich get a total of 6 bytes

Private OutPos As Long              'invoeg positie voor de output array
Private OutBitCount As Integer
Private OutByteBuf As Byte
Private ReadBitPos As Integer
Private NumExtBits(7) As Byte

Private Type Grouping
    LowValue As Long
    HighValue As Long
    NumInGroup As Long
End Type
   
Private Sub Init_Grouping()
    OutPos = 0              'Next position in the output stream
    OutBitCount = 0         'Number of bits stored in the output buffer
    OutByteBuf = 0          'byte wich will be stores in outputstream if it is filled with 8 bits
    ReadBitPos = 0          'next position wich will be read
'This array is used to determen the amount of bits used to store a number
    NumExtBits(0) = 3       '<8
    NumExtBits(1) = 3       '<16
    NumExtBits(2) = 4       '<32
    NumExtBits(3) = 5       '<64
    NumExtBits(4) = 6       '<128
    NumExtBits(5) = 7       '<256
    NumExtBits(6) = 8       '<512
    NumExtBits(7) = 16      'the rest
End Sub

Public Sub Compress_SmartGrouping(ByteArray() As Byte)
    Dim OutStream() As Byte         'The output array
    Dim BeginGroup As Long          'Start for the next bytes wich will be compressed
    Dim BestGroup As Integer        'Best grouping method to get the best result
    Dim NewBest As Integer          'used to check if there is maybe a better method
    Dim BitsDeep As Integer         'This is used as a dummy
    Dim X As Long
    Dim TotFileLen As Long          'total file len
    Dim Group(1 To 8) As Grouping
    TotFileLen = UBound(ByteArray)
    ReDim OutStream(TotFileLen + (TotFileLen / 7))  'Worst case scenario
    BeginGroup = 0
'whe start by setting the beginvalues
    Call Init_Grouping
'lets check if we have done the whole file
    Do While BeginGroup < TotFileLen
        Group(8).LowValue = 0
        Group(8).HighValue = 255
        Group(8).NumInGroup = TotFileLen - BeginGroup + 1
'If where not ready yet whe assume the best method of compression is no compression
'That is indeed the best method cause nocompression needs 9 additional bits and compression uses 17
        BestGroup = 8
'lets check if there is maybe a better way
        NewBest = CheckForBetterWithin(ByteArray, Group, BestGroup, BeginGroup)
        Do While BestGroup <> NewBest
'yes there is, lets check again to be shure
            BestGroup = NewBest
            NewBest = CheckForBetterWithin(ByteArray, Group, BestGroup, BeginGroup)
        Loop
'whe have found the best method
        If BestGroup = 8 Then
            BitsDeep = 0            'No compression
        Else
            BitsDeep = BestGroup
        End If
'here we will store the header in into the outputstream
        Call AddGroupCodeToStream(OutStream, Group(BestGroup).NumInGroup, BitsDeep)
'If we have found compression then we must store also the lowest value of the group
'opslaan minimum waarde van de groep
        If BestGroup <> 8 Then
            Call AddBitsToStream(OutStream, CLng(Group(BestGroup).LowValue), 8)
        End If
'here we will read the bytes from the inputstream, convert them, and store them
'into the output stream
        For X = BeginGroup To BeginGroup + Group(BestGroup).NumInGroup - 1
            Call AddBitsToStream(OutStream, CLng(ByteArray(X) - Group(BestGroup).LowValue), BestGroup)
        Next
        BeginGroup = BeginGroup + Group(BestGroup).NumInGroup
    Loop
'if the grouping part is complete we have to store the EOF-marker = 0
'0 = no compression ,marker for less than 8 bytes, and 0 bytes to store
    Call AddGroupCodeToStream(OutStream, 0, 0)
'maybe we have some bits leftover so lets store them
    If OutBitCount < 8 Then
        Do While OutBitCount < 8
            OutByteBuf = OutByteBuf * 2
            OutBitCount = OutBitCount + 1
        Loop
        OutStream(OutPos) = OutByteBuf: OutPos = OutPos + 1
    End If
    OutPos = OutPos - 1
    ReDim ByteArray(OutPos)
'lets copy the outputstream into the inputstream so that we can return the compressed file
'to the caller
    Call CopyMem(ByteArray(0), OutStream(0), OutPos + 1)
End Sub

'This part is used to select the extra bits used to store a value
Private Function GetExtraBitsNum(Number As Long)
    Select Case Number
    Case Is < 8
        GetExtraBitsNum = 0
    Case Is < 16
        GetExtraBitsNum = 1
    Case Is < 32
        GetExtraBitsNum = 2
    Case Is < 64
        GetExtraBitsNum = 3
    Case Is < 128
        GetExtraBitsNum = 4
    Case Is < 256
        GetExtraBitsNum = 5
    Case Is < 512
        GetExtraBitsNum = 6
    Case Else
        GetExtraBitsNum = 7
    End Select
End Function

Private Sub AddGroupCodeToStream(ToStream() As Byte, Number As Long, GroupNum As Integer)
    Dim NumVal As Byte
    Dim X As Long
'Store 3 bits to say what grouping method is used
    Call AddBitsToStream(ToStream, CLng(GroupNum), 3)
    NumVal = GetExtraBitsNum(Number)
'store 3 bits to with will tell the amount of bits to be read to get the groupsize
    Call AddBitsToStream(ToStream, CLng(NumVal), 3)
'store 3 to 16 bits to put in the groepsize
    Call AddBitsToStream(ToStream, Number, CInt(NumExtBits(NumVal)))
End Sub

'this sub will add an amount of bits into the outputstream
Private Sub AddBitsToStream(ToStream() As Byte, Number As Long, Numbits As Integer)
    Dim X As Long
    For X = Numbits - 1 To 0 Step -1
        OutByteBuf = OutByteBuf * 2 + (-1 * ((Number And 2 ^ X) > 0))
        OutBitCount = OutBitCount + 1
        If OutBitCount = 8 Then: ToStream(OutPos) = OutByteBuf: OutBitCount = 0: OutByteBuf = 0: OutPos = OutPos + 1
    Next
End Sub

'This is Smart part of the grouping method
'it will look for the way to get the best compression
Private Function CheckForBetterWithin(InArray() As Byte, Group() As Grouping, MaxGroup As Integer, StartPositie As Long)
    Dim LowInGroup As Integer               'lowest value found
    Dim HighInGroup As Integer              'highest value found
    Dim GroupSize As Integer                'size of the group 1-7
    Dim NumInGroup As Long                  'total numbers in group
    Dim RealBegin As Long
    Dim BestGroep As Integer                'the best group found
    Dim NewBestGroep As Integer             'check for bestgroup
    Dim StartGroep As Integer               'startgroup to hold the group wich will be checked for better comp.
    Dim BestCompression As Long             'maximum compression (for now)
    Dim WheHaveCompression As Boolean       'whe have found a better method
    Dim Char As Integer                     'character found in input stream
    Dim BitsNoComp As Long                  'bits used if no comp.
    Dim BitsComp As Long                    'bits used if comp.
    Dim CheckLen As Long                    'maximum bytes to check
    Dim StartPos As Long                    'startposition where the check will start
    StartPos = StartPositie
    RealBegin = StartPos
    StartGroep = MaxGroup
    CheckForBetterWithin = MaxGroup

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
99精品热视频| 久久色中文字幕| 日韩免费高清av| 国产精品毛片无遮挡高清| 亚洲午夜在线视频| 高潮精品一区videoshd| 欧美剧情片在线观看| 中文字幕日韩av资源站| 加勒比av一区二区| 7777精品伊人久久久大香线蕉| 久久久久久久性| 男女视频一区二区| 欧美日韩视频第一区| 亚洲日本成人在线观看| 国产高清一区日本| 26uuu久久综合| 麻豆成人在线观看| 欧美一区二区三区喷汁尤物| 亚洲国产精品久久久久秋霞影院| 成人午夜伦理影院| 国产欧美一区二区精品久导航| 日本 国产 欧美色综合| 欧美日韩精品欧美日韩精品一综合| 中文字幕巨乱亚洲| 成人动漫av在线| 国产精品色呦呦| 成人黄色大片在线观看| 欧美极品少妇xxxxⅹ高跟鞋| 精品一区二区三区日韩| 日韩美一区二区三区| www.欧美色图| 国产精品激情偷乱一区二区∴| 国产乱国产乱300精品| 久久精品免费在线观看| 国产成人午夜精品5599| 国产女人18毛片水真多成人如厕 | 日韩视频在线一区二区| 午夜伦欧美伦电影理论片| 欧美亚洲动漫制服丝袜| 亚洲超丰满肉感bbw| 欧美一区二区三区小说| 精品一区二区精品| 国产欧美一区二区精品秋霞影院| 国产成人精品免费视频网站| 中文字幕第一区| 91免费国产视频网站| 亚洲精品国产无套在线观| 欧美日韩国产电影| 免费在线观看不卡| 国产欧美精品一区二区色综合| 成人av电影免费在线播放| 中文字幕中文在线不卡住| 日本乱人伦一区| 日日摸夜夜添夜夜添精品视频| 欧美一区二区三区在线视频| 精品在线播放免费| 亚洲视频每日更新| 欧美日韩卡一卡二| 国产乱码精品1区2区3区| 亚洲码国产岛国毛片在线| 欧美精选一区二区| 国产寡妇亲子伦一区二区| 亚洲欧美日韩一区二区| 欧美一区二区三区视频免费| 国产aⅴ精品一区二区三区色成熟| 1024亚洲合集| 日韩免费成人网| 99精品在线免费| 丝袜亚洲另类欧美| 日本一区二区视频在线| 欧美日韩视频在线第一区| 国产99久久久国产精品| 亚洲成人av一区二区| 国产欧美日韩精品一区| 欧美挠脚心视频网站| 成人h精品动漫一区二区三区| 亚洲成人免费视| 欧美国产一区在线| 欧美一区二区三区在线视频| 99r国产精品| 国内成人自拍视频| 婷婷六月综合亚洲| 国产精品99久久久久久久vr| 亚洲成人一区二区在线观看| 国产精品久久久久久久第一福利| 91麻豆精品国产91久久久| 99精品在线观看视频| 国产一区二区主播在线| 日韩专区欧美专区| 亚洲天堂成人网| 久久久亚洲精品石原莉奈| 欧美疯狂做受xxxx富婆| 99综合电影在线视频| 国产一区二区三区免费| 裸体一区二区三区| 亚洲国产另类av| 亚洲精品欧美二区三区中文字幕| 久久影院电视剧免费观看| 欧美一卡二卡在线观看| 欧美日韩免费观看一区二区三区 | 精品在线免费视频| 天堂影院一区二区| 亚洲图片欧美一区| 亚洲最新在线观看| 亚洲一区二区高清| 亚洲精品国产一区二区三区四区在线 | 色综合久久久久| 粉嫩av亚洲一区二区图片| 激情国产一区二区| 国产在线精品免费av| 免费看精品久久片| 视频一区二区三区入口| 亚洲一区二区三区爽爽爽爽爽| 国产精品丝袜黑色高跟| 中文字幕av资源一区| 国产精品青草久久| 亚洲欧美日韩人成在线播放| 自拍偷在线精品自拍偷无码专区| 中文字幕亚洲不卡| 亚洲人成精品久久久久久 | 久久亚洲综合色一区二区三区| 日韩欧美国产1| 久久丝袜美腿综合| 中文字幕中文字幕一区二区| 国产精品的网站| 亚洲男人天堂av网| 午夜精品久久久久久| 欧美a级一区二区| 紧缚奴在线一区二区三区| 国产精品一区二区你懂的| 国产成人精品免费看| 波多野结衣中文一区| 91麻豆产精品久久久久久| 欧美日韩一卡二卡| 精品国产一区二区在线观看| 久久精品夜色噜噜亚洲aⅴ| 国产精品美女一区二区在线观看| 国产日韩欧美精品一区| 亚洲精品欧美在线| 免费在线观看视频一区| 国产a视频精品免费观看| 色综合天天综合网天天看片| 欧美日韩精品福利| 精品国产一区二区国模嫣然| 亚洲国产精品ⅴa在线观看| 一区二区高清在线| 免费观看在线综合| 成人性生交大片免费看中文| 91性感美女视频| 欧美一级午夜免费电影| 中文字幕一区二区三区乱码在线| 亚洲国产精品久久不卡毛片 | 欧美中文字幕亚洲一区二区va在线 | 精品成人a区在线观看| 国产精品精品国产色婷婷| 日韩精品视频网站| 国产成人免费视频 | 一本久久精品一区二区 | 欧美在线999| 国产日韩欧美一区二区三区综合| 亚洲一区二区高清| 成人免费观看视频| 91精品国产欧美一区二区成人| 久久久www成人免费毛片麻豆| 亚洲精品videosex极品| 国产一区二区网址| 欧美一区二区三区视频在线观看| 中文字幕国产一区| 黄色日韩三级电影| 欧美三级视频在线观看| 国产精品嫩草影院com| 狠狠网亚洲精品| 51精品久久久久久久蜜臀| 综合久久久久久| 国产99久久精品| 精品国产一区二区三区av性色| 亚洲国产精品嫩草影院| av一本久道久久综合久久鬼色| 日韩三级.com| 日本伊人色综合网| 欧美日韩一区 二区 三区 久久精品| 国产精品久久久久久久岛一牛影视 | 亚洲图片欧美视频| 91麻豆swag| 亚洲欧美一区二区三区国产精品| 国产麻豆精品一区二区| 日韩欧美精品三级| 日本不卡一区二区| 欧美精品欧美精品系列| 亚洲一区二区三区免费视频| 91在线观看地址| 国产精品久久国产精麻豆99网站| 国产大陆精品国产| 国产午夜久久久久| 国产69精品一区二区亚洲孕妇| 精品剧情v国产在线观看在线| 麻豆成人久久精品二区三区小说| 91麻豆精品国产91久久久| 日本在线不卡一区| 精品日韩在线观看|