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

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

?? transferidct_mmx.c

?? MPEG4解碼源代碼
?? C
字號:
/**************************************************************************
 *                                                                        *
 * This code has been developed by John Funnell. This software is an      *
 * implementation of a part of one or more MPEG-4 Video tools as          *
 * specified in ISO/IEC 14496-2 standard.  Those intending to use this    *
 * software module in hardware or software products are advised that its  *
 * use may infringe existing patents or copyrights, and any such use      *
 * would be at such party's own risk.  The original developer of this     *
 * software module and his/her company, and subsequent editors and their  *
 * companies (including Project Mayo), will have no liability for use of  *
 * this software or modifications or derivatives thereof.                 *
 *                                                                        *
 * Project Mayo gives users of the Codec a license to this software       *
 * module or modifications thereof for use in hardware or software        *
 * products claiming conformance to the MPEG-4 Video Standard as          *
 * described in the Open DivX license.                                    *
 *                                                                        *
 * The complete Open DivX license can be found at                         *
 * http://www.projectmayo.com/opendivx/license.php                        *
 *                                                                        *
 **************************************************************************/
/**
*  Copyright (C) 2001 - Project Mayo
 *
 * John Funnell
 *
 * DivX Advanced Research Center <darc@projectmayo.com>
**/
// transferIDCT_mmx.c //

/* routines to transfer iDCT block result into the output picture */

/* this routine still needs to be optimised for pipelining        */
/* just haven't got time to finish the optimisations here ;-)     */

/* inline masm is used here so not compatible with gnu            */



//#define _TEST_TRANSFER

#ifdef _TEST_TRANSFER
#include <stdio.h>
#endif


#include "portab.h"

void transferIDCT_add(int16_t *sourceS16, uint8_t *destU8, int stride) {
	#ifdef _TEST_TRANSFER
	uint8_t reference_dest[64];
	int x, y, sum16;

	/* populate reference_dest[] with the correct result... */
	for (y=0; y<8; y++) {
		for (x=0; x<8; x++) {
			sum16 = (destU8[stride*y + x] + sourceS16[8*y + x]);
			if      (sum16 > 255) reference_dest[8*y + x] = 255;
			else if (sum16 <   0) reference_dest[8*y + x] =   0;
			else                  reference_dest[8*y + x] = (uint8_t)sum16;
		}
	}
	#endif

	_asm {

	; not sure about the state handling here - there must be a better way
	push eax
	push ebx
	push edi

	mov eax, sourceS16           ;  parameter 1, *sourceS16
	mov ebx, destU8              ;  parameter 2, *destU8
	mov edi, stride              ;  parameter 3, stride
	pxor mm7, mm7                ;  set mm7 = 0

; lines 0 to 7 all scheduled in together
	movq mm0,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm1,  mm0               ;  eight bytes of destination into mm0
	punpcklbw mm0, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm1, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm0, qword ptr [eax]  ;  add source and destination
	paddsw mm1, qword ptr [eax+8];  add source and destination
	packuswb mm0, mm1            ;  pack mm0 and mm1 into mm0
	movq  qword ptr  [ebx], mm0  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm2,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm3,  mm2               ;  eight bytes of destination into mm3
	punpcklbw mm2, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm3, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm2, qword ptr [eax+16]  ;  add source and destination
	paddsw mm3, qword ptr [eax+24];  add source and destination
	packuswb mm2, mm3            ;  pack mm0 and mm1 into mm0
	movq  qword ptr  [ebx], mm2  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm4,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm5,  mm4               ;  eight bytes of destination into mm5
	punpcklbw mm4, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm5, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm4, qword ptr [eax+32]  ;  add source and destination
	paddsw mm5, qword ptr [eax+40];  add source and destination
	packuswb mm4, mm5            ;  pack mm0 and mm1 into mm0
	movq  qword ptr  [ebx], mm4  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm0,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm1,  qword ptr [ebx]   ;  eight bytes of destination into mm5
	punpcklbw mm0, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm1, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm0, qword ptr [eax+48]  ;  add source and destination
	paddsw mm1, qword ptr [eax+56];  add source and destination
	packuswb mm0, mm1            ;  pack mm0 and mm1 into mm0
	add eax, 64                  ;  add +64 to source ptr                
	movq  qword ptr  [ebx], mm0  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm2,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm3,  mm2               ;  eight bytes of destination into mm3
	punpcklbw mm2, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm3, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm2, qword ptr [eax]  ;  add source and destination
	paddsw mm3, qword ptr [eax+8];  add source and destination
	packuswb mm2, mm3            ;  pack mm0 and mm1 into mm0
	add eax, 16                  ;  add +16 to source ptr                
	movq  qword ptr  [ebx], mm2  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm4,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm5,  mm4               ;  eight bytes of destination into mm5
	punpcklbw mm4, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm5, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm4, qword ptr [eax]  ;  add source and destination
	paddsw mm5, qword ptr [eax+8];  add source and destination
	packuswb mm4, mm5            ;  pack mm0 and mm1 into mm0
	add eax, 16                  ;  add +16 to source ptr                
	movq  qword ptr  [ebx], mm4  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm0,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm1,  mm0               ;  eight bytes of destination into mm1
	punpcklbw mm0, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm1, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm0, qword ptr [eax]  ;  add source and destination
	paddsw mm1, qword ptr [eax+8];  add source and destination
	packuswb mm0, mm1            ;  pack mm0 and mm1 into mm0
	add eax, 16                  ;  add +16 to source ptr                
	movq  qword ptr  [ebx], mm0  ;  copy output to destination
	add ebx, edi                 ;  add +stride to dest ptr

	movq mm2,  qword ptr [ebx]   ;  eight bytes of destination into mm4
	movq mm3,  mm2               ;  eight bytes of destination into mm3
	punpcklbw mm2, mm7           ;  unpack first 4 bytes from dest into mm4
	punpckhbw mm3, mm7           ;  unpack next 4 bytes from dest into mm5
	paddsw mm2, qword ptr [eax]  ;  add source and destination
	paddsw mm3, qword ptr [eax+8];  add source and destination
	packuswb mm2, mm3            ;  pack mm0 and mm1 into mm0
	movq  qword ptr  [ebx], mm2  ;  copy output to destination

	pop edi
	pop ebx 
	pop eax

	emms


	}

	#ifdef _TEST_TRANSFER
	/* check destination against reference_dest[]... */
	for (y=0; y<8; y++) {
		for (x=0; x<8; x++) {
			if (reference_dest[8*y + x] != destU8[stride*y + x]) printf("transferIDCT_add() is broken\n");
		}
	}
	#endif
  
}

void transferIDCT_copy(int16_t *sourceS16, uint8_t *destU8, int stride) {
	#ifdef _TEST_TRANSFER
	int x, y, clipped;
	#endif
	
	_asm {

	; not sure about the state handling here - there must be a better way
	push eax
	push ebx
	push edi

	mov eax, sourceS16           ;  parameter 1, *sourceS16
	mov ebx, destU8              ;  parameter 2, *destU8
	mov edi, stride              ;  parameter 3, stride

; lines 0 to 7 schedueled into each other...
	movq mm0, qword ptr [eax]       ;  move first four words into mm0

	packuswb mm0, qword ptr [eax+8] ;  pack mm0 and the next four words into mm0

	movq mm1, qword ptr [eax+16]    ;  move first four words into mm1

	packuswb mm1, qword ptr [eax+24];  pack mm0 and the next four words into mm1

	movq mm2, qword ptr [eax+32]    ;  move first four words into mm2

	packuswb mm2, qword ptr [eax+40];  pack mm0 and the next four words into mm2

	movq mm3, qword ptr [eax+48]    ;  move first four words into mm3

	packuswb mm3, qword ptr [eax+56] ;  pack mm3 and the next four words into mm3

	movq qword ptr [ebx], mm0       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr

	movq qword ptr [ebx], mm1       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr

	movq qword ptr [ebx], mm2       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr

	movq qword ptr [ebx], mm3       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr
	
	movq mm0, qword ptr [eax+64]    ;  move first four words into mm0
	add eax, 64                     ;  add 64 to source ptr                

	packuswb mm0, qword ptr [eax+8] ;  pack mm0 and the next four words into mm0

	movq mm1, qword ptr [eax+16]    ;  move first four words into mm1

	packuswb mm1, qword ptr [eax+24];  pack mm0 and the next four words into mm1

	movq mm2, qword ptr [eax+32]    ;  move first four words into mm2

	packuswb mm2, qword ptr [eax+40];  pack mm0 and the next four words into mm2

	movq mm3, qword ptr [eax+48]    ;  move first four words into mm3

	packuswb mm3, qword ptr [eax+56];  pack mm3 and the next four words into mm3

	movq qword ptr [ebx], mm0       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr

	movq qword ptr [ebx], mm1       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr

	movq qword ptr [ebx], mm2       ;  copy output to destination
	add ebx, edi                    ;  add +stride to dest ptr

	movq qword ptr [ebx], mm3       ;  copy output to destination

	pop edi
	pop ebx 
	pop eax

	emms

	}

	#ifdef _TEST_TRANSFER
	for (y=0; y<8; y++) {
		for (x=0; x<8; x++) {
			clipped = sourceS16[8*y + x];
			if (clipped > 255) clipped = 255;
			if (clipped <   0) clipped =   0;
			if (clipped != destU8[stride*y+x]) printf("transferIDCT_copy() is broken\n");
		}
	}
	#endif

}




?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲精品欧美在线| 亚洲人成小说网站色在线| 免费在线观看视频一区| 欧美高清激情brazzers| 香蕉久久一区二区不卡无毒影院| 欧美日韩精品一二三区| 日韩国产在线观看一区| 精品日产卡一卡二卡麻豆| 国产乱码精品一区二区三区av| 欧美精品一区二区在线观看| 成人理论电影网| 亚洲一区二区三区小说| 91精品国产综合久久福利| 青青草成人在线观看| 久久精品一二三| 91高清视频免费看| 麻豆国产精品一区二区三区| 久久九九影视网| 一本色道**综合亚洲精品蜜桃冫 | 欧美性高清videossexo| 三级欧美在线一区| 日本一区二区不卡视频| 欧美日韩在线播| 国内成人免费视频| 一区二区三区免费在线观看| 日韩精品一区二区在线| 色综合天天综合狠狠| 日韩高清在线电影| 日本一区二区三区久久久久久久久不| 91亚洲大成网污www| 日韩av中文字幕一区二区| 国产欧美日韩三区| 91精品国产高清一区二区三区| 成人综合婷婷国产精品久久蜜臀| 亚洲成在人线免费| 日本一区二区成人| 欧美一区二区黄| 99v久久综合狠狠综合久久| 手机精品视频在线观看| 国产精品乱码一区二区三区软件| 欧美老年两性高潮| eeuss鲁片一区二区三区在线看| 偷拍一区二区三区| 亚洲欧洲成人自拍| 久久久午夜精品理论片中文字幕| 欧美日韩视频在线一区二区| 97se亚洲国产综合自在线不卡| 精品亚洲免费视频| 视频在线观看91| 亚洲综合精品自拍| 亚洲人吸女人奶水| 国产三级久久久| 精品久久久久久久久久久久包黑料| 欧美午夜片在线观看| 91色视频在线| 波多野结衣一区二区三区| 精品一区二区av| 日本成人在线视频网站| 性做久久久久久| 亚洲九九爱视频| 亚洲欧洲国产日韩| 国产精品女主播在线观看| 久久久蜜桃精品| 精品伦理精品一区| 制服丝袜日韩国产| 91麻豆精品91久久久久同性| 欧美丝袜丝交足nylons| 91色在线porny| 色综合天天综合在线视频| 成人污视频在线观看| 国产成人亚洲精品狼色在线| 国产精品自在在线| 国产一区二区在线看| 国产在线精品一区二区不卡了 | 欧美主播一区二区三区| 日韩一级大片在线观看| 不卡欧美aaaaa| 成人激情开心网| 成人精品小蝌蚪| 国产精品久久久久久福利一牛影视 | 日韩成人伦理电影在线观看| 蜜桃91丨九色丨蝌蚪91桃色| 99视频热这里只有精品免费| 欧美三级电影网| 中文字幕不卡在线| 日日夜夜精品视频免费| av中文字幕亚洲| 日韩女优视频免费观看| 亚洲品质自拍视频| 国产尤物一区二区在线| 欧美色国产精品| 中文字幕乱码亚洲精品一区| 日本欧美久久久久免费播放网| 成人午夜免费av| 欧美大片拔萝卜| 亚洲综合一二三区| 国产成人精品亚洲777人妖| 91精品国产综合久久蜜臀| 国产日产精品一区| 免费人成网站在线观看欧美高清| 99天天综合性| 久久久蜜臀国产一区二区| 天天综合网天天综合色| 91丨porny丨在线| 久久婷婷成人综合色| 首页综合国产亚洲丝袜| 91论坛在线播放| 中文一区一区三区高中清不卡| 免费人成精品欧美精品| 欧美日韩精品系列| 一区二区免费在线播放| 波多野结衣中文字幕一区二区三区| 精品国内片67194| 午夜精品久久久久久不卡8050| 不卡在线视频中文字幕| 国产拍揄自揄精品视频麻豆| 久久精品国产亚洲高清剧情介绍| 欧美视频中文一区二区三区在线观看| 国产精品午夜在线| 国产69精品久久777的优势| 日韩亚洲欧美成人一区| 亚洲成人三级小说| 在线观看日韩高清av| 亚洲欧美一区二区三区久本道91| 成人一区二区三区在线观看| 久久精品亚洲麻豆av一区二区| 精品在线播放午夜| 欧美一二三四区在线| 五月天欧美精品| 欧美日韩大陆在线| 亚洲1区2区3区4区| 91麻豆精品国产91久久久久| 亚洲成a人v欧美综合天堂下载| 欧洲国内综合视频| 亚洲午夜精品网| 欧美日韩日日骚| 丝袜亚洲另类丝袜在线| 欧美日韩aaa| 美女视频第一区二区三区免费观看网站| 欧美日韩成人高清| 同产精品九九九| 欧美一区二区性放荡片| 美国十次综合导航| 久久综合狠狠综合| 成人黄色在线视频| 亚洲天堂福利av| 色婷婷狠狠综合| 亚洲gay无套男同| 日韩欧美一卡二卡| 国产乱国产乱300精品| 亚洲国产激情av| 色嗨嗨av一区二区三区| 亚洲二区视频在线| 91精品婷婷国产综合久久竹菊| 奇米亚洲午夜久久精品| 久久亚洲精华国产精华液| 懂色av一区二区三区蜜臀| 国产精品成人在线观看| 欧洲av在线精品| 麻豆91在线观看| 久久久九九九九| 日本高清视频一区二区| 日韩电影一二三区| 久久影视一区二区| 99久久99久久久精品齐齐| 性感美女久久精品| 久久精品夜色噜噜亚洲aⅴ| 972aa.com艺术欧美| 日韩主播视频在线| 久久久久99精品一区| 色婷婷激情一区二区三区| 美女国产一区二区三区| 国产精品每日更新在线播放网址 | 色综合色综合色综合色综合色综合| 亚洲一区二区三区视频在线播放| 欧美一区二区三区的| 国产精品一区二区视频| 亚洲香肠在线观看| 久久精品视频在线免费观看| 在线观看精品一区| 激情都市一区二区| 亚洲综合一二区| 国产三级一区二区三区| 欧美撒尿777hd撒尿| 国产麻豆91精品| 亚洲国产日韩精品| 日本一区二区视频在线观看| 欧美亚日韩国产aⅴ精品中极品| 精品中文av资源站在线观看| 一区二区三区欧美激情| 国产欧美日韩另类一区| 欧美一级夜夜爽| 在线欧美日韩国产| 丰满放荡岳乱妇91ww| 日本aⅴ精品一区二区三区| 亚洲视频一区二区在线| 久久久久久9999| 日韩欧美高清在线| 欧美日韩国产首页| 色视频成人在线观看免|