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

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

?? jpegfileformat.java

?? 源碼為Eclipse開源開發(fā)平臺桌面開發(fā)工具SWT的源代碼,
?? JAVA
?? 第 1 頁 / 共 4 頁
字號:
	int k = 1;	while (k < 64) {		int rs = decodeUsingTable(acTable);		int r = rs >> 4;		int s = rs & 0xF;		if (s == 0) {			if (r == 15) {				k += 16;			} else {				break;			}		} else {			k += r;			int bits = receive(s);			dataUnit[ZigZag8x8[k]] = extendBy(bits, s);			k++;		}	}}void decodeACFirstCoefficients(int[] dataUnit, int iComp, int start, int end, int approxBit) {	if (eobrun > 0) {		eobrun--;		return;	}	int[] sParams = scanHeader.componentParameters[componentIds[iComp]];	JPEGHuffmanTable acTable = acHuffmanTables[sParams[AC]];	int k = start;	while (k <= end) {		int rs = decodeUsingTable(acTable);		int r = rs >> 4;		int s = rs & 0xF;		if (s == 0) {			if (r == 15) {				k += 16;			} else {				eobrun = (1 << r) + receive(r) - 1;				break;			}		} else {			k += r;			int bits = receive(s);			dataUnit[ZigZag8x8[k]] = extendBy(bits, s) << approxBit;			k++;		}	}}void decodeACRefineCoefficients(int[] dataUnit, int iComp, int start, int end, int approxBit) {	int[] sParams = scanHeader.componentParameters[componentIds[iComp]];	JPEGHuffmanTable acTable = acHuffmanTables[sParams[AC]];	int k = start;	while (k <= end) {		if (eobrun > 0) {			while (k <= end) {				int zzIndex = ZigZag8x8[k];				if (dataUnit[zzIndex] != 0) {					dataUnit[zzIndex] = refineAC(dataUnit[zzIndex], approxBit);				}				k++;			}			eobrun--;		} else {			int rs = decodeUsingTable(acTable);			int r = rs >> 4;			int s = rs & 0xF;			if (s == 0) {				if (r == 15) {					int zeros = 0;					while (zeros < 16 && k <= end) {						int zzIndex = ZigZag8x8[k];						if (dataUnit[zzIndex] != 0) {							dataUnit[zzIndex] = refineAC(dataUnit[zzIndex], approxBit);						} else {							zeros++;						}						k++;					}				} else {					eobrun = (1 << r) + receive(r);				}			} else {				int bit = receive(s);				int zeros = 0;				int zzIndex = ZigZag8x8[k];				while ((zeros < r || dataUnit[zzIndex] != 0) && k <= end) {					if (dataUnit[zzIndex] != 0) {						dataUnit[zzIndex] = refineAC(dataUnit[zzIndex], approxBit);					} else {						zeros++;					}					k++;					zzIndex = ZigZag8x8[k];				}				if (bit != 0) {					dataUnit[zzIndex] = 1 << approxBit;				} else {					dataUnit[zzIndex] = -1 << approxBit;				}				k++;			}		}	}}int refineAC(int ac, int approxBit) {	if (ac > 0) {		int bit = nextBit();		if (bit != 0) {			ac = ac + (1 << approxBit);		}	} else if (ac < 0) {		int bit = nextBit();		if (bit != 0) {			ac = ac + (-1 << approxBit);		}	}	return ac;}void decodeDCCoefficient(int[] dataUnit, int iComp, boolean first, int approxBit) {	int[] sParams = scanHeader.componentParameters[componentIds[iComp]];	JPEGHuffmanTable dcTable = dcHuffmanTables[sParams[DC]];	int lastDC = 0;	if (progressive && !first) {		int bit = nextBit();		lastDC = dataUnit[0] + (bit << approxBit);	} else {		lastDC = precedingDCs[iComp];		int nBits = decodeUsingTable(dcTable);		if (nBits != 0) {			int bits = receive(nBits);			int diff = extendBy(bits, nBits);			lastDC = lastDC + diff;			precedingDCs[iComp] = lastDC;		}		if (progressive) {			lastDC = lastDC << approxBit;		}	}	dataUnit[0] = lastDC;}void dequantize(int[] dataUnit, int iComp) {	int[] qTable = quantizationTables[frameComponents[componentIds[iComp]][TQI]];	for (int i = 0; i < dataUnit.length; i++) {		int zzIndex = ZigZag8x8[i];		dataUnit[zzIndex] = dataUnit[zzIndex] * qTable[i];	}}byte[] decodeImageComponents() {	int[] compIds = new int[nComponents];	int compIdsIndex = 0;	for (int i = 0; i < nComponents; i++) {		compIds[compIdsIndex] = i + 1;		compIdsIndex++;	}	if ((compIds.length == 3) &&		(compIds[0] == 1) &&		(compIds[1] == 2) &&		(compIds[2] == 3)) {			return convertYCbCrToRGB();	}	if ((compIds.length == 3) &&		(compIds[0] == 1) &&		(compIds[1] == 4) &&		(compIds[2] == 5)) {			return convertYIQToRGB();	}	if (compIds.length == 4) {		return convertCMYKToRGB();	}	return convertYToRGB();}void decodeMCUAtXAndY(int xmcu, int ymcu, int nComponentsInScan, boolean first, int start, int end, int approxBit) {	for (int iComp = 0; iComp < nComponentsInScan; iComp++) {		int scanComponent = iComp;		while (scanHeader.componentParameters[componentIds[scanComponent]] == null) {			scanComponent++;		}		int[] frameComponent = frameComponents[componentIds[scanComponent]];		int hi = frameComponent[HI];		int vi = frameComponent[VI];		if (nComponentsInScan == 1) {			hi = 1;			vi = 1;		}		int compWidth = frameComponent[CW];		for (int ivi = 0; ivi < vi; ivi++) {			for (int ihi = 0; ihi < hi; ihi++) {				if (progressive) {					// Progressive: First scan - create a new data unit.					// Subsequent scans - refine the existing data unit.					int index = (ymcu * vi + ivi) * compWidth + xmcu * hi + ihi;					dataUnit = dataUnits[scanComponent][index];					if (dataUnit == null) {						dataUnit = new int[64];						dataUnits[scanComponent][index] = dataUnit;					}				} else {					// Sequential: Clear and reuse the data unit buffer.					for (int i = 0; i < dataUnit.length; i++) {						dataUnit[i] = 0;					}				}				if (!progressive || scanHeader.isDCProgressiveScan()) {					decodeDCCoefficient(dataUnit, scanComponent, first, approxBit);				}				if (!progressive) {					decodeACCoefficients(dataUnit, scanComponent);				} else {					if (scanHeader.isACProgressiveScan()) {						if (first) {							decodeACFirstCoefficients(dataUnit, scanComponent, start, end, approxBit);						} else {							decodeACRefineCoefficients(dataUnit, scanComponent, start, end, approxBit);						}					}					if (loader.hasListeners()) {						// Dequantization, IDCT, up-sampling and color conversion						// are done on a copy of the coefficient data in order to						// display the image incrementally.						int[] temp = dataUnit;						dataUnit = new int[64];						System.arraycopy(temp, 0, dataUnit, 0, 64);					}				}				if (!progressive || (progressive && loader.hasListeners())) {					dequantize(dataUnit, scanComponent);					inverseDCT(dataUnit);					storeData(dataUnit, scanComponent, xmcu, ymcu, hi, ihi, vi, ivi);				}			}		}	}}void decodeScan() {	if (progressive && !scanHeader.verifyProgressiveScan()) {		SWT.error(SWT.ERROR_INVALID_IMAGE);	}	int nComponentsInScan = scanHeader.getNumberOfImageComponents();	int mcuRowsInScan = interleavedMcuRows;	int mcusPerRow = interleavedMcuCols;	if (nComponentsInScan == 1) {		// Non-interleaved.		int scanComponent = 0;		while (scanHeader.componentParameters[componentIds[scanComponent]] == null) {			scanComponent++;		}		int[] frameComponent = frameComponents[componentIds[scanComponent]];		int hi = frameComponent[HI];		int vi = frameComponent[VI];		int mcuWidth = DCTSIZE * maxH / hi;		int mcuHeight = DCTSIZE * maxV / vi;		mcusPerRow = (imageWidth + mcuWidth - 1) / mcuWidth;		mcuRowsInScan = (imageHeight + mcuHeight - 1) / mcuHeight;	}	boolean first = scanHeader.isFirstScan();	int start = scanHeader.getStartOfSpectralSelection();	int end = scanHeader.getEndOfSpectralSelection();	int approxBit = scanHeader.getApproxBitPositionLow();	restartsToGo = restartInterval;	nextRestartNumber = 0;	for (int ymcu = 0; ymcu < mcuRowsInScan; ymcu++) {		for (int xmcu = 0; xmcu < mcusPerRow; xmcu++) {			if (restartInterval != 0) {				if (restartsToGo == 0) processRestartInterval();				restartsToGo--;			}			decodeMCUAtXAndY(xmcu, ymcu, nComponentsInScan, first, start, end, approxBit);		}	}}int decodeUsingTable(JPEGHuffmanTable huffmanTable) {	int i = 0;	int[] maxCodes = huffmanTable.getDhMaxCodes();	int[] minCodes = huffmanTable.getDhMinCodes();	int[] valPtrs = huffmanTable.getDhValPtrs();	int[] huffVals = huffmanTable.getDhValues();	int code = nextBit();	while (code > maxCodes[i]) {		code = code * 2 + nextBit();		i++;	}	int j = valPtrs[i];	j = j + code - minCodes[i];	return huffVals[j];}void emit(int huffCode, int nBits) {	if (nBits == 0) {		SWT.error(SWT.ERROR_INVALID_IMAGE);	}	int[] power2m1 = new int[] {		1, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095, 8191, 		16383, 32767, 65535, 131125	};	int code = (huffCode & power2m1[nBits - 1]) << (24 - nBits - currentBitCount);	byte[] codeBuffer = new byte[4];	codeBuffer[0] = (byte)(code % 256);	codeBuffer[1] = (byte)((code / 256) % 256);	codeBuffer[2] = (byte)((code / 65536) % 256);	codeBuffer[3] = (byte)((code / 16777216) % 256);	int abs = nBits - (8 - currentBitCount);	if (abs < 0) abs = -abs;	if ((abs / 8) > 0) {		currentByte += codeBuffer[2];		emitByte((byte)currentByte);		emitByte((byte)codeBuffer[1]);		currentByte = codeBuffer[0];		currentBitCount += nBits - 16;	} else {		currentBitCount += nBits;		if (currentBitCount >= 8) {			currentByte += codeBuffer[2];			emitByte((byte)currentByte);			currentByte = codeBuffer[1];			currentBitCount -= 8;		} else {			currentByte += codeBuffer[2];		}	}}void emitByte(byte byteValue) {	if (bufferCurrentPosition >= 512) {		resetOutputBuffer();	}	dataBuffer[bufferCurrentPosition] = byteValue;	bufferCurrentPosition++;	if (byteValue == -1) {		emitByte((byte)0);	}}void encodeACCoefficients(int[] dataUnit, int iComp) {	int[] sParams = scanHeader.componentParameters[iComp];	JPEGHuffmanTable acTable = acHuffmanTables[sParams[AC]];	int[] ehCodes = acTable.ehCodes;	byte[] ehSizes = acTable.ehCodeLengths;	int r = 0;	int k = 1;	while (k < 64) {		k++;		int acValue = dataUnit[ZigZag8x8[k - 1]];		if (acValue == 0) {			if (k == 64) {				emit(ehCodes[0], ehSizes[0] & 0xFF);			} else {				r++;			}		} else {			while (r > 15) {				emit(ehCodes[0xF0], ehSizes[0xF0] & 0xFF);				r -= 16;			}			if (acValue < 0) {				int absACValue = acValue;				if (absACValue < 0) absACValue = -absACValue;				int nBits = NBitsTable[absACValue];				int rs = r * 16 + nBits;				emit(ehCodes[rs], ehSizes[rs] & 0xFF);				emit(0xFFFFFF - absACValue, nBits);			} else {				int nBits = NBitsTable[acValue];				int rs = r * 16 + nBits;				emit(ehCodes[rs], ehSizes[rs] & 0xFF);				emit(acValue, nBits);			}			r = 0;		}	}}void encodeDCCoefficients(int[] dataUnit, int iComp) {	int[] sParams = scanHeader.componentParameters[iComp];	JPEGHuffmanTable dcTable = dcHuffmanTables[sParams[DC]];	int lastDC = precedingDCs[iComp];	int dcValue = dataUnit[0];	int diff = dcValue - lastDC;	precedingDCs[iComp] = dcValue;	if (diff < 0) {		int absDiff = 0 - diff;		int nBits = NBitsTable[absDiff];		emit(dcTable.ehCodes[nBits], dcTable.ehCodeLengths[nBits]);		emit(0xFFFFFF - absDiff, nBits);	} else {		int nBits = NBitsTable[diff];		emit(dcTable.ehCodes[nBits], dcTable.ehCodeLengths[nBits]);		if (nBits != 0) {			emit(diff, nBits);		}	}}void encodeMCUAtXAndY(int xmcu, int ymcu) {	int nComponentsInScan = scanHeader.getNumberOfImageComponents();	dataUnit = new int[64];	for (int iComp = 0; iComp < nComponentsInScan; iComp++) {		int[] frameComponent = frameComponents[componentIds[iComp]];		int hi = frameComponent[HI];		int vi = frameComponent[VI];		for (int ivi = 0; ivi < vi; ivi++) {			for (int ihi = 0; ihi < hi; ihi++) {				extractData(dataUnit, iComp, xmcu, ymcu, ihi, ivi);				forwardDCT(dataUnit);				quantizeData(dataUnit, iComp);				encodeDCCoefficients(dataUnit, iComp);				encodeACCoefficients(dataUnit, iComp);			}		}	}}void encodeScan() {	for (int ymcu = 0; ymcu < interleavedMcuRows; ymcu++) {		for (int xmcu = 0; xmcu < interleavedMcuCols; xmcu++) {			encodeMCUAtXAndY(xmcu, ymcu);		}	}	if (currentBitCount != 0) {		emitByte((byte)currentByte);	}	resetOutputBuffer();}void expandImageComponents() {	for (int iComp = 0; iComp < nComponents; iComp++) {		int[] frameComponent = frameComponents[componentIds[iComp]];		int hi = frameComponent[HI];		int vi = frameComponent[VI];		int upH = maxH / hi;		int upV = maxV / vi;		if ((upH * upV) > 1) {			byte[] component = imageComponents[iComp];			int compWidth = frameComponent[CW];			int compHeight = frameComponent[CH];			int upCompWidth = compWidth * upH;			int upCompHeight = compHeight * upV;			RGB[] rgbs = new RGB[] {				new RGB(0,0,0),				new RGB(0x80,0,0),				new RGB(0,0x80,0),				new RGB(0x80,0x80,0),				new RGB(0,0,0x80),				new RGB(0x80,0,0x80),				new RGB(0,0x80,0x80),				new RGB(0xC0,0xC0,0xC0),				new RGB(0x80,0x80,0x80),				new RGB(0xFF,0,0),				new RGB(0,0xFF,0),				new RGB(0xFF,0xFF,0),				new RGB(0,0,0xFF),				new RGB(0xFF,0,0xFF),				new RGB(0,0xFF,0xFF),				new RGB(0xFF,0xFF,0xFF),			};			ImageData src = new ImageData(compWidth, compHeight, 8, new PaletteData(rgbs), 4, component);			ImageData dest = src.scaledTo(upCompWidth, upCompHeight);			imageComponents[iComp] = dest.data;		}	}}int extendBy(int diff, int t) {	if (diff < ExtendTest[t]) {		return diff + ExtendOffset[t];	} else {		return diff;	}}void extractData(int[] dataUnit, int iComp, int xmcu, int ymcu, int ihi, int ivi) {	byte[] compImage = imageComponents[iComp];	int[] frameComponent = frameComponents[componentIds[iComp]];	int hi = frameComponent[HI];	int vi = frameComponent[VI];	int compWidth = frameComponent[CW];	int srcIndex = ((ymcu * vi + ivi) * compWidth * DCTSIZE) + ((xmcu * hi + ihi) * DCTSIZE);	int destIndex = 0;	for (int i = 0; i < DCTSIZE; i++) {		for (int col = 0; col < DCTSIZE; col++) {			dataUnit[destIndex] = (compImage[srcIndex + col] & 0xFF) - 128;			destIndex++;		}		srcIndex += compWidth;	}}void forwardDCT(int[] dataUnit) {

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
中文字幕亚洲综合久久菠萝蜜| 欧美日本在线播放| 欧美成人国产一区二区| 日韩一区二区电影网| 国产色婷婷亚洲99精品小说| 亚洲色图.com| 国产伦精品一区二区三区视频青涩 | 免费在线视频一区| 成人丝袜18视频在线观看| 在线免费观看一区| 国产日韩欧美亚洲| 欧美伊人久久久久久午夜久久久久| 日韩美女视频一区二区在线观看| 亚洲美女电影在线| 处破女av一区二区| 日韩理论片中文av| 91精品国产综合久久小美女| 亚洲精品免费播放| 国产.欧美.日韩| 精品99一区二区三区| 日韩精彩视频在线观看| 色乱码一区二区三区88| 国产精品久久久久一区二区三区| 免费成人美女在线观看| 天天射综合影视| 欧美日本一道本| 国产成人在线观看免费网站| 久久美女高清视频| 国产乱码字幕精品高清av| 精品国产免费一区二区三区四区| 成人小视频免费观看| 亚洲第一福利一区| 欧美网站一区二区| 国内精品国产成人国产三级粉色| 精品少妇一区二区三区| 95精品视频在线| 国产成人午夜视频| 亚洲在线视频网站| 欧美日韩一区二区在线视频| 一区二区三区在线免费观看| 欧洲亚洲国产日韩| 丁香啪啪综合成人亚洲小说 | 欧美日韩国产首页| 国产iv一区二区三区| 日韩精品免费视频人成| 国产精品久久久久精k8| www激情久久| 欧美午夜电影网| 国产一区二区精品久久91| 亚洲电影视频在线| 国产精品久久久久国产精品日日| 日韩欧美国产1| 色婷婷国产精品| 日韩av电影天堂| 精品成人免费观看| 欧美日韩第一区日日骚| 色综合中文综合网| 国产精品一区二区三区乱码| 舔着乳尖日韩一区| 一二三四区精品视频| 国产精品免费看片| 欧美视频一区二区三区在线观看| 国产成人福利片| 国产精品资源在线看| 免费观看在线综合| 天天操天天色综合| 亚洲第一激情av| 亚洲国产成人高清精品| 亚洲第一激情av| 有坂深雪av一区二区精品| 日韩一区在线免费观看| 国产精品毛片a∨一区二区三区| 久久综合av免费| 26uuu国产电影一区二区| 亚洲精品一区二区三区蜜桃下载| 欧美一级久久久| 91精品国产麻豆| 成人动漫一区二区在线| 爽好久久久欧美精品| 亚洲va韩国va欧美va| 午夜亚洲福利老司机| 午夜视频在线观看一区二区| 婷婷成人综合网| 一本色道久久综合亚洲91| 日本黄色一区二区| 欧美一a一片一级一片| 欧美日韩精品一区二区天天拍小说 | 亚洲在线免费播放| 偷偷要91色婷婷| 毛片av中文字幕一区二区| 亚洲另类一区二区| 亚洲一区中文日韩| 日本女优在线视频一区二区| 韩国欧美国产1区| 成人夜色视频网站在线观看| av动漫一区二区| 在线播放视频一区| eeuss鲁片一区二区三区| 99视频热这里只有精品免费| 一本一道综合狠狠老| 91在线国产福利| 欧美精品一二三四| 久久久精品tv| 亚洲精品欧美激情| 日本在线不卡一区| 国产精品一品二品| 色婷婷av一区二区三区大白胸 | 日韩午夜激情免费电影| 国产女主播视频一区二区| 亚洲欧美另类图片小说| 色综合久久综合网97色综合| 欧美日韩中文一区| 精品噜噜噜噜久久久久久久久试看| 国产女主播一区| 天天色天天爱天天射综合| 高清不卡一二三区| 欧美日韩成人在线一区| 日本一区二区三区电影| 一区二区三区日本| 国产精品456露脸| 色美美综合视频| 精品国产乱码久久久久久浪潮| 亚洲天堂精品在线观看| 麻豆精品在线视频| 91国偷自产一区二区开放时间 | 成人欧美一区二区三区视频网页 | 秋霞电影一区二区| 99久久久精品免费观看国产蜜| 欧美人与禽zozo性伦| 国产精品成人免费精品自在线观看| 天天爽夜夜爽夜夜爽精品视频| jlzzjlzz欧美大全| 欧美videos大乳护士334| 亚洲综合男人的天堂| 国产91丝袜在线播放0| 日韩欧美一区二区免费| 亚洲欧美激情一区二区| 丰满白嫩尤物一区二区| 日韩欧美视频在线| 亚洲大片免费看| 91网页版在线| 一区二区中文字幕在线| 老司机一区二区| 国产大片一区二区| 日韩欧美国产高清| 亚洲成人一区二区在线观看| 99综合电影在线视频| 久久久久久久电影| 捆绑调教一区二区三区| 91精品国产综合久久婷婷香蕉 | 欧美精品一区二区久久婷婷| 亚洲小说欧美激情另类| 91视频你懂的| 国产精品久久久久7777按摩| 欧美日韩成人一区二区| 亚洲精品免费在线| 91蝌蚪国产九色| 国产精品色婷婷| 成人激情校园春色| 久久免费午夜影院| 国产精品亚洲一区二区三区妖精 | 日韩欧美一区二区三区在线| 丝瓜av网站精品一区二区| 欧美性色欧美a在线播放| 亚洲摸摸操操av| 欧美综合一区二区| 亚洲一区二区免费视频| 欧美亚洲综合色| 一本色道**综合亚洲精品蜜桃冫| 欧美高清在线精品一区| 亚洲精品日韩一| 91国内精品野花午夜精品| 亚洲嫩草精品久久| 欧洲av在线精品| 亚洲国产综合91精品麻豆| 欧美日韩国产小视频在线观看| 午夜精品久久久| 日韩女优制服丝袜电影| 国产一区在线观看视频| 中文字幕精品一区二区精品绿巨人 | 亚洲一卡二卡三卡四卡| 欧美在线制服丝袜| jvid福利写真一区二区三区| 亚洲美腿欧美偷拍| 欧美日韩一区二区不卡| 日本视频一区二区| 久久精品夜色噜噜亚洲a∨| 成人国产精品免费观看视频| 最新日韩av在线| 欧美三级中文字幕| 麻豆91精品视频| 久久久久国产精品麻豆ai换脸| 成人免费高清在线观看| 亚洲无线码一区二区三区| 91精品国产黑色紧身裤美女| 国产美女精品人人做人人爽 | 欧美日韩另类一区| 九九视频精品免费| 亚洲一区二区三区四区在线观看 | 亚洲已满18点击进入久久|