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

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

?? compressor.vhd

?? vhdl source for jpeg beginner
?? VHD
?? 第 1 頁 / 共 5 頁
字號:
      --in this process data are sent to the DCT1 component, its output is quantized and written back      --in the same addresses where they were read (buffers) to be sent to DCT1.      variable Columna : std_logic_vector(9 downto 0);      variable Linea : std_logic_vector(3 downto 0); --0 to 15      variable Bloque : std_logic_vector(1 downto 0);      variable DCTQ : std_logic_vector(24 downto 0); --for multiplication of the result of the DCT with numerator of Q            variable Base : std_logic_vector(8 downto 0); --to access Q coefficients from the tables in ROM      variable BaseH : std_logic_vector(8 downto 0); --for the Huffman tables ROM      variable BaseQ : std_logic_vector(8 downto 0); --for the Q tables ROM           variable HuffmanWord : std_logic_vector(22 downto 0);      variable HuffmanWordPos : integer range -1 to 22;      variable LumaBlock : std_logic;       variable Elemento : std_logic_vector(1 downto 0);      variable Coeficiente : integer range 0 to 63; --indicates which is the next coefficient to be processed by Huffman      variable PrevDC : std_logic_vector(11 downto 0); --previous value of luminance DC      variable Coef : std_logic_vector(11 downto 0); --current coefficient's value      variable LastBlockDCY : std_logic_vector(11 downto 0);      variable LastBlockDCCb : std_logic_vector(11 downto 0);      variable LastBlockDCCr : std_logic_vector(11 downto 0);      variable IniDC : std_logic;      variable FirstDC : std_logic;      variable GetPrevDC : std_logic;      variable ColBk : std_logic_vector(9 downto 0);      variable LinBk : std_logic_vector(3 downto 0); --0 to 15      variable Hlength : integer range 0 to 15;      variable ZeroRun : integer range 0 to 16;      variable ZRL : integer range 0 to 3;      variable WriteZRL : std_logic;      variable Cat : integer range 0 to 11;      variable Sign : std_logic;      variable Primera : std_logic;      variable HeaderFinal : std_logic; --to know if we've already written EOI (End Of Image)      variable VarTamImg : std_logic_vector(10 downto 0);      variable DatoHeader : integer range 0 to 7 := 0; --to know where we are in the writing of the header's image size      variable TempCompDC : std_logic_vector(14 downto 0);      variable AddVal : std_logic_vector(11 downto 0);      variable QDC : std_logic_vector(12 downto 0);      --pragma translate_off            --I couldn't find any testbench where I could read or write binary files and the ones I found were overcomplex      --so I experimented and found this to be a useful way to do it without any complications.      type ByteT is (c0,c1,c2,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c22,c23,c24,c25,c26,c27,c28,c29,c30,c31,c32,c33,c34,c35,c36,c37,c38,c39,c40,c41,c42,c43,c44,c45,c46,c47,c48,c49,c50,c51,c52,c53,c54,c55,c56,c57,c58,c59,c60,c61,c62,c63,c64,c65,c66,c67,c68,c69,c70,c71,c72,c73,c74,c75,c76,c77,c78,c79,c80,c81,c82,c83,c84,c85,c86,c87,c88,c89,c90,c91,c92,c93,c94,c95,c96,c97,c98,c99,c100,c101,c102,c103,c104,c105,c106,c107,c108,c109,c110,c111,c112,c113,c114,c115,c116,c117,c118,c119,c120,c121,c122,c123,c124,c125,c126,c127,c128,c129,c130,c131,c132,c133,c134,c135,c136,c137,c138,c139,c140,c141,c142,c143,c144,c145,c146,c147,c148,c149,c150,c151,c152,c153,c154,c155,c156,c157,c158,c159,c160,c161,c162,c163,c164,c165,c166,c167,c168,c169,c170,c171,c172,c173,c174,c175,c176,c177,c178,c179,c180,c181,c182,c183,c184,c185,c186,c187,c188,c189,c190,c191,c192,c193,c194,c195,c196,c197,c198,c199,c200,c201,c202,c203,c204,c205,c206,c207,c208,c209,c210,c211,c212,c213,c214,c215,c216,c217,c218,c219,c220,c221,c222,c223,c224,c225,c226,c227,c228,c229,c230,c231,c232,c233,c234,c235,c236,c237,c238,c239,c240,c241,c242,c243,c244,c245,c246,c247,c248,c249,c250,c251,c252,c253,c254,c255);      subtype Byte is ByteT; --well, maybe I oversubtyped it, hehe      type ByteFileType is file of Byte;      file outfile : ByteFileType open write_mode is "image.jpg";      variable Pixel : Byte;   	variable bufer: LINE;      variable Header : std_logic_vector(4855 downto 0) := X"FFD8FFE000104A46494600010200000100010000FFC00011080020004003012200021101031101FFDB008400100B0C0E0C0A100E0D0E1211101318281A181616183123251D283A333D3C3933383740485C4E404457453738506D51575F626768673E4D71797064785C656763011112121815182F1A1A2F634238426363636363636363636363636363636363636363636363636363636363636363636363636363636363636363636363636363FFC401A20000010501010101010100000000000000000102030405060708090A0B100002010303020403050504040000017D01020300041105122131410613516107227114328191A1082342B1C11552D1F02433627282090A161718191A25262728292A3435363738393A434445464748494A535455565758595A636465666768696A737475767778797A838485868788898A92939495969798999AA2A3A4A5A6A7A8A9AAB2B3B4B5B6B7B8B9BAC2C3C4C5C6C7C8C9CAD2D3D4D5D6D7D8D9DAE1E2E3E4E5E6E7E8E9EAF1F2F3F4F5F6F7F8F9FA0100030101010101010101010000000000000102030405060708090A0B1100020102040403040705040400010277000102031104052131061241510761711322328108144291A1B1C109233352F0156272D10A162434E125F11718191A262728292A35363738393A434445464748494A535455565758595A636465666768696A737475767778797A82838485868788898A92939495969798999AA2A3A4A5A6A7A8A9AAB2B3B4B5B6B7B8B9BAC2C3C4C5C6C7C8C9CAD2D3D4D5D6D7D8D9DAE2E3E4E5E6E7E8E9EAF2F3F4F5F6F7F8F9FAFFDA000C03010002110311003F00";      --pragma translate_on   begin      if (reset = '1') then         CompressingInt <= '0';         Linea := (others => '0');         Columna := (others => '0');         Bloque := "00";         StepV <= 0;         weY2 <= '0';         weCb2 <= '0';         weCr2 <= '0';         Base := (others => '0');         BaseH := (others => '0');         BaseQ := (others => '0');                 DCTQ := (others => '0');         DIND <= (others => '0');         ND <= '0';         --Huffmanear <= '0';         PrevDC := (others => '0');         Coeficiente := 0;         HuffmanWord := (others => '0');         HuffmanWordPos := 22; --first free LSB (HuffmanWord's MSB)         Elemento := "00";         IniDC := '1';         GetPrevDC := '1';         FirstDC := '1';         Save <= '0';         addri <= "0000000000101100"; --first Table         addribk <= "0000001001011110"; --pointer to last Header byte         addrH <= (others => '0');         addrQ <= (others => '0');         addrCb2 <= (others => '0');         addrCr2 <= (others => '0');         addrY2 <= (others => '0');         din <= (others => '0');         we <= '0';         dinY2 <= (others => '0');         dinCr2 <= (others => '0');         dinCb2 <= (others => '0');         Done <= '0';         Cat := 0;         ZRL := 0;         Coef := (others => '0');         ColBk := (others => '0');         LinBk := (others => '0');         Sign := '0';         ZeroRun := 0;         Primera := '0';         LumaBlock := '0';         NDe <= '0';                    HeaderFinal := '0';         DatoHeader := 0;         VarTamImg := (others => '0');             WriteAdditionalBits <= '0';         TempCompDC := (others => '0');         WriteZRL := '0';         LastBlockDCY := (others => '0');         LastBlockDCCb := (others => '0');         LastBlockDCCr := (others => '0');                     AddVal := (others => '0');                         QDC := (others => '0');         WriteTables <= '0';         TableData <= (others => '0');         Table <= '0';             addrTablaQ <= (others => '0');         ZRLing <= '0';                RFDInt <= '0';         RFDIntData <= (others => '0');      elsif (clk = '1' and clk'event) then         if CompressImage = '1' then            FirstDC := '1';            IniDC := '1';            HeaderFinal := '0';            GetPrevDC := '1';            PrevDC := (others => '0'); --initialized to zero at the beginning of the image            HuffmanWord := (others => '0');            HuffmanWordPos := 22;            Save <= '0';            DatoHeader := 0;            WriteAdditionalBits <= '0';            HeaderFinal := '0';            WriteTables <= '1';            TableData <= (others => '0');            Table <= '0';            addribk <= "0000001001011110"; --pointer to the Header's last byte            addri <= "0000000000101100"; --first Table            case Compression is               when "00" => --low quality                  BaseQ := "100000000";               when "01" => --medium quality                  BaseQ := "010000000";               when others => --10 high quality                  BaseQ := "000000000";            end case;            addrTablaQ <= BaseQ; --ready first data            CompressingInt <= '0';            Bloque := "00";            StepV <= 0;            weY2 <= '0';            weCb2 <= '0';            weCr2 <= '0';            Base := (others => '0');            BaseH := (others => '0');            ND <= '0';            Coeficiente := 0;            we <= '0';            Done <= '0';                        ZRLing <= '0';            RFDInt <= '0';            RFDIntData <= (others => '0');            --pragma translate_off               Columna := ('0' & ImgLines) + 1;                                 for i in 606 downto 563 loop                  case i is                     when (606-25) => --MSByte of size Y                        Pixel := ByteT'val(conv_integer("0000000" & Columna(8)));                     when (606-26) => --LSByte of size Y                        Pixel := ByteT'val(conv_integer(Columna(7 downto 0)));                        Columna := ImgColumns + 1;                     when (606-27) => --MSByte of size X                        Pixel := ByteT'val(conv_integer("000000" & Columna(9 downto 8)));                     when (606-28) => --LSByte of size X                        Pixel := ByteT'val(conv_integer(Columna(7 downto 0)));                     when others =>                        Pixel := ByteT'val(conv_integer(Header(8*i+7 downto 8*i)));                  end case;                        write(outfile, Pixel);               end loop;                        --pragma translate_on                     end if;         we <= '0'; --after the ones that rise it         if WriteTables = '1' then --write in memory the quantization tables for the selected compression level            if Table = '0' then --the start of Table Q of value "00h" is in position 2Bh (43=101011)               addri <= "0000000000101100" + ('0' & TableData);            else--the start of Table Q of value "01h" is in position 6Ch (108=1101100)                addri <= "0000000001101101" + ('0' & TableData);            end if;               din <= doutTablaQ;            addrTablaQ <= addrTablaQ + 1;                        if addrTablaQ /= BaseQ then --first coefficient, not written because we'll have it also in next cycle               --until second coefficient is loaded               we <= '1';               TableData <= TableData + 1;               --pragma translate_off               Pixel := ByteT'val(conv_integer(doutTablaQ));               write(outfile, Pixel);               --pragma translate_on                        end if;                        if TableData = "111111" then               if Table = '1' then --we are over                  --pragma translate_off                  for i in 433 downto 0 loop                     Pixel := ByteT'val(conv_integer(Header(8*i+7 downto 8*i)));                     write(outfile, Pixel);                  end loop;                              --pragma translate_on                                    WriteTables <= '0';                  addrTablaQ <= (others => '0'); --so that it doesn't stay in a non-existent address               else                     Table <= '1';                                   --pragma translate_off                  Pixel := ByteT'val(1); --points to the start of Table 01                  write(outfile, Pixel);                  --pragma translate_on                                             end if;               end if;            end if;                     if (MakeDCT = '1' or CompressingInt = '1') then --MakeDCT lasts only one cycle, but CompressingInt is high the following ones            if MakeDCT = '1' then               HeaderFinal := '0';               --write the image size, now that we know it, in the header as at the least we must do               --4 DCTs in an image, there won't be any problem if image size writing is done in four steps               --or if it is repeated throughout the image's processing               case DatoHeader is                  when 0 => --MSByte of ImgLines+1                     addri <= "0000000000011001"; --position 0 of the two bytes of size Y (lines)                     we <= '1';                     VarTamImg := ("00" & ImgLines) + 1;                     din <= "000000" & VarTamImg(9 downto 8);                     DatoHeader := 1;                  when 1 => --LSByte of ImgLines+1                     addri <= "0000000000011010";                      we <= '1';                     din <= VarTamImg(7 downto 0);                     DatoHeader := 2;                  when 2 => --MSByte of ImgColumns+1                     addri <= "0000000000011011"; --position 0 of the two bytes of size X (columns)                     we <= '1';                     VarTamImg := ('0' & ImgColumns) + 1;                     din <= "00000" & VarTamImg(10 downto 8);                     DatoHeader := 3;                  when 3 => --LSByte of ImgColumns+1                     addri <= "0000000000011100";                      we <= '1';                     din <= VarTamImg(7 downto 0);                     DatoHeader := 4;                  when 4 to 7 => --it's been already written, don't do anything(we put 8 DatoHeader because in the last                     --block when we pass to the next image, ImgLines is zero and it is wrongly written)                     we <= '0';                     if DatoHeader = 7 then                        DatoHeader := 0;                     else                        DatoHeader := DatoHeader + 1;                     end if;                  end case;               CompressingInt <= '1';               if ColumnToCompress = "0000000000" then --we've changed line, careful                  --because we have to process the last block of the previous line                  Linea := (not LineToCompress(3)) & "000";                  Columna := ImgColumns(9 downto 3) & "000";               else                  Linea := LineToCompress(3) & "000";

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产ts人妖一区二区| 日韩精品中文字幕一区二区三区| 欧美精品日日鲁夜夜添| 久久精品网站免费观看| 亚洲成人av一区| av在线播放一区二区三区| 欧美一级日韩一级| 一区二区三区在线播放| 国内外成人在线视频| 欧美亚洲综合另类| 中文字幕一区二区三| 久草这里只有精品视频| 5月丁香婷婷综合| 伊人色综合久久天天人手人婷| 国产成人综合在线| 欧美日韩的一区二区| 中文字幕一区av| 国产91丝袜在线观看| 久久亚洲二区三区| 免费一级片91| 777亚洲妇女| 亚洲第一av色| 欧美日韩一级黄| 一区二区三区自拍| 色噜噜狠狠色综合中国| 亚洲婷婷在线视频| 色婷婷激情久久| 亚洲婷婷国产精品电影人久久| 99久精品国产| 最新不卡av在线| 99久久婷婷国产综合精品| 亚洲欧洲精品一区二区精品久久久 | 日本亚洲欧美天堂免费| 欧美女孩性生活视频| 亚洲电影视频在线| 成人一区在线观看| 国产精品无码永久免费888| 国产69精品久久久久777| 国产亚洲精品bt天堂精选| 国产一区二区三区综合| 久久精品欧美一区二区三区不卡 | 欧美精品久久天天躁| 三级久久三级久久久| 69久久夜色精品国产69蝌蚪网| 亚洲妇女屁股眼交7| 欧美日韩国产不卡| 美女脱光内衣内裤视频久久影院| 日韩你懂的在线观看| 国产在线乱码一区二区三区| 精品国产一区二区精华| 丁香天五香天堂综合| 亚洲色图都市小说| 欧美美女黄视频| 精品一区二区久久久| 国产欧美久久久精品影院| 99这里只有久久精品视频| 亚洲一区二区三区不卡国产欧美| 555www色欧美视频| 国产一区欧美日韩| 自拍偷拍亚洲欧美日韩| 欧美日韩国产免费| 激情深爱一区二区| 亚洲素人一区二区| 欧美一区二区精品| 播五月开心婷婷综合| 亚洲成在人线在线播放| 精品久久久久久最新网址| 99久久久国产精品免费蜜臀| 日韩综合小视频| 中文字幕日本不卡| 欧美麻豆精品久久久久久| 国产成人一级电影| 亚洲午夜一区二区| 久久这里都是精品| 欧美丝袜自拍制服另类| 国产在线精品一区二区三区不卡| 中文字幕日韩av资源站| 欧美不卡视频一区| 日本精品一区二区三区高清| 黄色日韩网站视频| 亚洲一区二区精品视频| 国产日产亚洲精品系列| 91精品国产乱| 成人免费高清视频| 青青草精品视频| 一区二区欧美视频| 亚洲国产电影在线观看| 日韩欧美不卡在线观看视频| 色婷婷av一区二区三区之一色屋| 韩国精品主播一区二区在线观看| 午夜精品久久久久久久久| 国产精品国产三级国产| 精品久久人人做人人爰| 91.成人天堂一区| 欧美性猛片aaaaaaa做受| 成人涩涩免费视频| 国产综合成人久久大片91| 亚洲国产另类av| 亚洲午夜久久久久久久久电影网| 欧美极品aⅴ影院| 久久综合一区二区| 日韩免费高清电影| 欧美一卡在线观看| 制服.丝袜.亚洲.中文.综合| 在线看一区二区| 色系网站成人免费| 97国产一区二区| 97久久精品人人爽人人爽蜜臀| 国产69精品久久久久毛片| 国产精品一区二区91| 久久精品国产一区二区| 免费人成网站在线观看欧美高清| 午夜激情综合网| 亚洲网友自拍偷拍| 亚洲一区二区影院| 一区二区在线观看av| 亚洲一区二区综合| 亚洲一区成人在线| 亚洲高清免费一级二级三级| 一区二区三区av电影| 亚洲一区免费在线观看| 午夜久久久影院| 日韩一区精品字幕| 免费观看日韩av| 国产一区二区精品久久91| 精品一区二区三区在线观看| 精品亚洲成a人| 国模无码大尺度一区二区三区| 久久av老司机精品网站导航| 国内成人自拍视频| 国产成人av影院| 成人性生交大片免费看中文| 97久久久精品综合88久久| 欧美视频在线不卡| 欧美一区二区三级| 国产亚洲va综合人人澡精品| 国产精品女同一区二区三区| 一区二区在线观看免费| 日日摸夜夜添夜夜添精品视频| 美女爽到高潮91| 国产成人综合亚洲91猫咪| 91影视在线播放| 欧美午夜精品一区二区蜜桃 | 久久亚洲私人国产精品va媚药| 欧美激情一区二区三区不卡| ...xxx性欧美| 午夜国产不卡在线观看视频| 久久精品国产99久久6| 不卡的电视剧免费网站有什么| 在线国产电影不卡| 久久亚洲综合色一区二区三区| 国产精品国产三级国产aⅴ入口| 亚洲高清免费一级二级三级| 国产麻豆精品在线观看| 在线一区二区三区做爰视频网站| 欧美一区二区三区视频免费| 国产精品毛片大码女人| 午夜久久久久久久久| 成人av午夜影院| 欧美一卡在线观看| 依依成人综合视频| 国产福利91精品| 欧美欧美欧美欧美| 综合电影一区二区三区| 国内精品伊人久久久久影院对白| 91麻豆免费视频| 国产三级精品三级在线专区| 亚洲一区av在线| 91在线丨porny丨国产| 精品国产伦一区二区三区观看方式 | 91精品欧美久久久久久动漫| 亚洲国产成人自拍| 亚洲精选在线视频| 欧美一级专区免费大片| 精品视频资源站| 久久久国产精品不卡| 日韩中文字幕亚洲一区二区va在线 | 亚洲一区二三区| 懂色av中文字幕一区二区三区 | 午夜欧美一区二区三区在线播放| 成人国产精品免费观看| 精品国产自在久精品国产| 亚洲国产精品久久久久婷婷884| 成人动漫一区二区在线| 欧美经典一区二区| 国产最新精品免费| 日韩精品在线一区二区| 蜜桃视频第一区免费观看| 欧美日韩在线播放| 亚洲一区二区三区在线| 91啦中文在线观看| 一区视频在线播放| 不卡在线观看av| 久久精品国产99国产| 久久久五月婷婷| 极品美女销魂一区二区三区| 日韩一区二区免费电影| 强制捆绑调教一区二区| 日韩欧美不卡一区| 久国产精品韩国三级视频|