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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? filebitstreamreaderagent.java

?? jpeg2000算法實現(xiàn)
?? JAVA
?? 第 1 頁 / 共 5 頁
字號:
/* * CVS identifier: * * $Id: FileBitstreamReaderAgent.java,v 1.44 2001/03/02 10:09:13 grosbois Exp $ * * Class:                   FileBitstreamReaderAgent * * Description:             Retrieve code-blocks codewords in the bit stream * * * * COPYRIGHT: *  * This software module was originally developed by Rapha雔 Grosbois and * Diego Santa Cruz (Swiss Federal Institute of Technology-EPFL); Joel * Askel鰂 (Ericsson Radio Systems AB); and Bertrand Berthelot, David * Bouchard, F閘ix Henry, Gerard Mozelle and Patrice Onno (Canon Research * Centre France S.A) in the course of development of the JPEG2000 * standard as specified by ISO/IEC 15444 (JPEG 2000 Standard). This * software module is an implementation of a part of the JPEG 2000 * Standard. Swiss Federal Institute of Technology-EPFL, Ericsson Radio * Systems AB and Canon Research Centre France S.A (collectively JJ2000 * Partners) agree not to assert against ISO/IEC and users of the JPEG * 2000 Standard (Users) any of their rights under the copyright, not * including other intellectual property rights, for this software module * with respect to the usage by ISO/IEC and Users of this software module * or modifications thereof for use in hardware or software products * claiming conformance to the JPEG 2000 Standard. Those intending to use * this software module in hardware or software products are advised that * their use may infringe existing patents. The original developers of * this software module, JJ2000 Partners and ISO/IEC assume no liability * for use of this software module or modifications thereof. No license * or right to this software module is granted for non JPEG 2000 Standard * conforming products. JJ2000 Partners have full right to use this * software module for his/her own purpose, assign or donate this * software module to any third party and to inhibit third parties from * using this software module for non JPEG 2000 Standard conforming * products. This copyright notice must be included in all copies or * derivative works of this software module. *  * Copyright (c) 1999/2000 JJ2000 Partners. * */package jj2000.j2k.codestream.reader;import jj2000.j2k.quantization.dequantizer.*;import jj2000.j2k.wavelet.synthesis.*;import jj2000.j2k.entropy.decoder.*;import jj2000.j2k.codestream.*;import jj2000.j2k.decoder.*;import jj2000.j2k.entropy.*;import jj2000.j2k.image.*;import jj2000.j2k.util.*;import jj2000.j2k.io.*;import jj2000.j2k.*;import java.util.*;import java.io.*;/** * This class reads the bit stream (with the help of HeaderDecoder for tile * headers and PktDecoder for packets header and body) and retrives location * of all code-block's codewords. * * <P>Note: All tile-parts headers are read by the constructor whereas packets * are processed when decoding related tile (when setTile method is called). * * <P>In parsing mode, the reader simulates a virtual layer-resolution * progressive bit stream with the same truncation points in each code-block, * whereas in truncation mode, only the first bytes are taken into account (it * behaves like if it is a real truncated codestream). * * @see HeaderDecoder * @see PktDecoder * */public class FileBitstreamReaderAgent extends BitstreamReaderAgent     implements Markers, ProgressionType, StdEntropyCoderOptions{    /** Reference to the PktDecoder instance */    public PktDecoder pktDec;        /** Reference to the ParameterList instance */    private ParameterList pl;    /** The RandomAccessIO where to get data from */    private RandomAccessIO in;    /** The number of tiles in the image */    private int nt;    /** Offset of the first packet in each tile-part in each tile */    private int[][] firstPackOff;    /** Number of bytes allocated to each tile. In parsing mode, this number     * is related to the tile length in the codestream whereas in truncation     * mode all the rate is affected to the first tiles. */    private int[] nBytes;    /** Length of each tile-part (written in Psot) */    private int[][] tilePartLen;    /** Total length of each tile */    private int[] totTileLen;    /** Total length of tiles' header */    private int[] totTileHeadLen;    /** First tile part header length*/    private int firstTilePartHeadLen;    /** Total length of all tile parts in all tiles */    private double totAllTileLen;    /** Length of main header */    private int mainHeadLen;    /** Length of all tile-part headers */    private int[][] tilePartHeadLen;    /** Length of each packet head found in the tile */    private Vector pktHL;    /** True if truncation mode is used. False if parsing mode */    private boolean isTruncMode;    /** The number of tile-parts that remain to read */    private int remainingTileParts;    /** The number of tile-parts read so far for each tile */    private int[] tilePartsRead;    /** Thetotal  number of tile-parts read so far */    private int totTilePartsRead=0;    /** The number of tile-parts in each tile */    private int[] tileParts;    /** The current tile part being used */    private int curTilePart;    /** The number of the tile-part in the codestream */    private int[][] tilePartNum;    /** Array containing info. for all the code-blocks:<br>     * - 1st dim: component index.<br>     * - 2nd dim: resolution level index.<br>     * - 3rd dim: subband index.<br>     * - 4th/5th dim: code-block index (vert. and horiz.).<br>     */    private CBlkInfo[][][][][] cbI;    /**      * Reads all tiles headers and keep offset of their first packet. Finally     * the rate allocation method is called.     *     * @param hd HeaderDecoder of the codestream.     *     * @param ehs The input stream where to read bit-stream.     *     * @param decSpec The decoder specifications      *     * @param pl The ParameterList instance created from the command-line     * arguments.     *     * @see #allocateRate     * */    public FileBitstreamReaderAgent(HeaderDecoder hd,RandomAccessIO ehs,                                    DecoderSpecs decSpec,ParameterList pl)    throws IOException {        super(hd,decSpec);                this.pl = pl;        String strInfo = "Codestream elements information in bytes "+            "(offset, total length, header length):\n\n";                // Get decoding rate        boolean rateInBytes;        boolean parsing = pl.getBooleanParameter("parsing");        try{            trate = pl.getFloatParameter("rate");        }        catch (NumberFormatException e) {            throw new Error("Invalid value in 'rate' option: "+                  pl.getParameter("rate"));        }        catch (IllegalArgumentException e) {            throw new Error("'rate' option is missing");        }                try{            tnbytes = pl.getIntParameter("nbytes");        }        catch (NumberFormatException e) {            throw new Error("Invalid value in 'nbytes' option: "+                  pl.getParameter("nbytes"));        }        catch (IllegalArgumentException e) {            throw new Error("'nbytes' option is missing");        }                // Check that '-rate' and '-nbytes' are not used at the same time        ParameterList defaults = pl.getDefaultParameterList();        if(tnbytes != defaults.getFloatParameter("nbytes"))            rateInBytes = true;        else            rateInBytes = false;        if(rateInBytes && trate != defaults.getIntParameter("rate")) {            throw new Error("Cannot use '-rate' and '-nbytes' options at the "+                  "same time.");        }        if(rateInBytes){            trate = tnbytes*8f/hd.getImgWidth()/hd.getImgHeight();        }        else {            tnbytes = (int)(trate*hd.getImgWidth()*hd.getImgHeight())/8;        }        isTruncMode = !pl.getBooleanParameter("parsing");        // initializations        nt = ntX * ntY;        in = ehs;        pktDec = new PktDecoder(decSpec,hd,ehs,this,isTruncMode);        tileParts = new int[nt];        totTileLen = new int[nt];	tilePartLen = new int[nt][];        tilePartNum = new int[nt][];        firstPackOff = new int[nt][];        tilePartsRead = new int[nt];        totTileHeadLen = new int[nt];	tilePartHeadLen = new int[nt][];	nBytes = new int[nt];        hd.nTileParts = new int[nt];	this.isTruncMode = isTruncMode;        int t=0, pos, tp=0, tptot=0;	// Keeps main header's length, takes file format into account        int cdstreamStart = hd.initPos; // Codestream offset in the file	mainHeadLen = in.getPos() - cdstreamStart;        anbytes = mainHeadLen;        strInfo += "Main header length    : "+cdstreamStart+", "+mainHeadLen+            ", "+mainHeadLen+"\n";        // If cannot even read the first tile-part        if(anbytes > tnbytes){            throw new Error("Requested bitrate is too small.");        }        // Read all tile-part headers from all tiles.	int tilePartStart;        boolean rateReached = false;        int mdl;        totAllTileLen = 0;        remainingTileParts = nt; // at least as many tile-parts as tiles        try{            while(remainingTileParts != 0){                tilePartStart = in.getPos();                // Read tile-part header		try{                    t = readTilePartHeader();                    tp = tilePartsRead[t];		}		catch(EOFException e){		    firstPackOff[t][tp]=in.length();		    throw e;		}                pos = in.getPos();                // In truncation mode, if target decoding rate is reached in                // tile-part header, skips the tile-part and stop reading                if(isTruncMode){                    if( (pos-cdstreamStart) > tnbytes ){                        firstPackOff[t][tp]=in.length();                        rateReached = true;                        break;                    }                }                                // Set tile part position and header length                firstPackOff[t][tp] = pos;                tilePartHeadLen[t][tp] = (pos-tilePartStart);                strInfo += "Tile-part "+tp+" of tile "+t+" : "+tilePartStart                    +", "+tilePartLen[t][tp]+", "+tilePartHeadLen[t][tp]+"\n";                // Update length counters                totTileLen[t] += tilePartLen[t][tp];                totTileHeadLen[t] += tilePartHeadLen[t][tp];                totAllTileLen += tilePartLen[t][tp];                if(isTruncMode){                    if(anbytes+tilePartLen[t][tp] > tnbytes) {                        anbytes += tilePartHeadLen[t][tp];                        rateReached = true;                        nBytes[t] += (tnbytes-anbytes);                        break;                    }                    else {                        anbytes += tilePartHeadLen[t][tp];                        nBytes[t] += (tilePartLen[t][tp]-                                      tilePartHeadLen[t][tp]);                    }                }                else {                    if(anbytes+tilePartHeadLen[t][tp] > tnbytes) {                        break;                    }                    else {                        anbytes += tilePartHeadLen[t][tp];                    }                }                                // If this is first tile-part, remember header length                if(tptot == 0)                    firstTilePartHeadLen = tilePartHeadLen[t][tp];                                // Go to the beginning of next tile part                tilePartsRead[t]++;                in.seek(tilePartStart+tilePartLen[t][tp]);                remainingTileParts--;                tptot++;            }        } catch(EOFException e) {            if(pl.getBooleanParameter("cdstr_info"))               FacilityManager.getMsgLogger().                   printmsg(MsgLogger.INFO,strInfo); 	    FacilityManager.getMsgLogger().		printmsg(MsgLogger.WARNING,"Codestream truncated in tile "+t);            // Bit-rate allocation            if(!isTruncMode)                allocateRate();            // Update 'res' value once all tile-part headers are read            if(pl.getParameter("res") == null){                res = decSpec.dls.getMin();            }            else{                try {                    res = pl.getIntParameter("res");                    if(res<0){                        throw new                            IllegalArgumentException("Specified negative "+                                                     "resolution level "+

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
a亚洲天堂av| 国产日产欧产精品推荐色| 色素色在线综合| 成人a区在线观看| 91搞黄在线观看| 欧美电影免费观看高清完整版在线观看 | 五月天激情综合| 麻豆成人av在线| 国产精品一区免费在线观看| 99综合电影在线视频| 中文字幕日韩欧美一区二区三区| 亚洲123区在线观看| 丁香激情综合国产| 制服丝袜国产精品| 中文字幕亚洲综合久久菠萝蜜| 成人一级片网址| 亚洲欧美日韩电影| 国产精品91一区二区| 国产精品免费aⅴ片在线观看| 青娱乐精品在线视频| 91在线小视频| 欧美国产日韩亚洲一区| 久久精品二区亚洲w码| 在线观看日韩av先锋影音电影院| 欧美激情在线观看视频免费| 97精品久久久午夜一区二区三区| 亚洲制服丝袜一区| 99精品黄色片免费大全| 亚洲成av人片观看| 国产色产综合产在线视频| 91国偷自产一区二区三区成为亚洲经典 | 日韩你懂的电影在线观看| 国产在线视视频有精品| 欧美精品v国产精品v日韩精品| 中文久久乱码一区二区| 欧美午夜影院一区| 亚洲精品成人精品456| 不卡的av中国片| 天堂在线一区二区| 欧美日韩视频专区在线播放| 亚洲另类中文字| 日韩欧美在线影院| 精品中文av资源站在线观看| 欧美美女一区二区三区| 国产.精品.日韩.另类.中文.在线.播放| ww久久中文字幕| 韩国欧美国产1区| 亚洲一区二区五区| 国产女人aaa级久久久级| 欧美日韩国产综合一区二区| 午夜精品久久久久久久久久久 | 亚洲国产日韩综合久久精品| 欧美亚洲高清一区二区三区不卡| 六月丁香综合在线视频| 亚洲午夜久久久久| 国产精品久久国产精麻豆99网站| 91在线丨porny丨国产| 美美哒免费高清在线观看视频一区二区 | 欧美一区二区观看视频| 国产乱人伦偷精品视频不卡 | 国产日韩影视精品| 欧美巨大另类极品videosbest | 99国产精品久久久| 国产一区二区三区在线观看免费视频| 2024国产精品视频| 欧美精品九九99久久| 91网上在线视频| 午夜激情一区二区| 自拍偷拍亚洲综合| 91精品综合久久久久久| 在线看一区二区| 在线观看一区日韩| 欧美在线不卡视频| 欧美无砖专区一中文字| 欧美视频中文一区二区三区在线观看| 91网站最新网址| 色综合久久综合| 91视频在线观看免费| 91色乱码一区二区三区| 99精品欧美一区| 在线精品视频一区二区三四| 色婷婷综合在线| 欧美影片第一页| 欧美另类一区二区三区| 欧美电影一区二区| 91精品国产免费久久综合| 欧美一级艳片视频免费观看| 欧美日韩mp4| 欧美一区二区三级| 精品国产1区2区3区| 欧美日韩中字一区| 欧美日韩国产小视频| 555夜色666亚洲国产免| 91精品国产高清一区二区三区| 日韩欧美一区二区免费| 精品久久久久久久人人人人传媒 | 91网站最新地址| 在线免费视频一区二区| 欧美日本一区二区| 欧美成人伊人久久综合网| 欧美精品一区二区在线观看| 欧美激情在线免费观看| 一区二区三区蜜桃| 国产精品女主播在线观看| 国产精品久久久久久久久图文区 | 欧美色图免费看| 日韩一区二区在线观看视频| 亚洲精品一区二区三区蜜桃下载 | 国产一区二区三区四区五区入口| 国产91精品久久久久久久网曝门| 9i在线看片成人免费| 欧美美女直播网站| 久久久久久久精| 日韩三级精品电影久久久| 国产喂奶挤奶一区二区三区| 亚洲私人影院在线观看| 午夜视频在线观看一区二区三区 | 天堂蜜桃91精品| 国内精品免费**视频| 91年精品国产| 精品国产网站在线观看| 亚洲少妇屁股交4| 蜜桃久久av一区| 91在线视频观看| 精品国产乱子伦一区| 亚洲美女电影在线| 另类小说色综合网站| 一本一本久久a久久精品综合麻豆 一本一道波多野结衣一区二区 | 免费成人深夜小野草| aa级大片欧美| 精品电影一区二区| 亚洲国产综合在线| 国产精品一区在线观看乱码| 欧美麻豆精品久久久久久| 中文字幕乱码亚洲精品一区| 日本aⅴ亚洲精品中文乱码| 91在线观看地址| 久久久一区二区| 免费观看一级欧美片| 欧美亚洲精品一区| 综合欧美亚洲日本| 5566中文字幕一区二区电影| 中文字幕一区二区三区四区| 狠狠色丁香婷婷综合久久片| 欧美伦理影视网| 亚洲一区二区在线视频| 不卡的av在线播放| 久久久亚洲精品石原莉奈| 日韩成人精品视频| 国产一区三区三区| 制服丝袜中文字幕亚洲| 一区二区三区精品在线| 成人av在线影院| 久久久久国色av免费看影院| 美女在线视频一区| 欧美日韩一区小说| 亚洲美女免费在线| 91丝袜美腿高跟国产极品老师 | av一本久道久久综合久久鬼色| 91精品国产一区二区| av综合在线播放| 久久先锋影音av鲁色资源网| 日本一区中文字幕| 欧美日韩国产不卡| 亚洲综合在线五月| 色999日韩国产欧美一区二区| 国产精品久久看| 懂色av中文字幕一区二区三区| 久久亚洲二区三区| 国产毛片精品一区| 久久精品一区八戒影视| 国内精品国产成人国产三级粉色 | 国产精品网站在线| 国产成人精品www牛牛影视| 成人免费视频网站在线观看| 精品国产欧美一区二区| 精品制服美女丁香| 精品欧美一区二区在线观看| 精品写真视频在线观看| 久久婷婷综合激情| 国产成人免费在线观看不卡| 国产精品蜜臀av| 一本大道av伊人久久综合| 一区二区三区日韩欧美| 欧美日韩中文另类| 蜜桃传媒麻豆第一区在线观看| 欧美一区二区网站| 狠狠色综合日日| 国产精品情趣视频| 色就色 综合激情| 婷婷丁香激情综合| 精品国产一区二区三区四区四| 国产精品一区2区| 中文字幕在线观看一区二区| 91麻豆精品在线观看| 天天综合色天天| 精品国产区一区| 一本色道综合亚洲| 日本v片在线高清不卡在线观看| 国产亚洲一区二区三区在线观看 |