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

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

?? graphic_generic.cc

?? 將konqueror瀏覽器移植到ARM9 2410中
?? CC
?? 第 1 頁 / 共 2 頁
字號:
////////////////////////////////////////////////////////////// Flash Plugin and Player// Copyright (C) 1998 Olivier Debon// // This program is free software; you can redistribute it and/or// modify it under the terms of the GNU General Public License// as published by the Free Software Foundation; either version 2// of the License, or (at your option) any later version.// // This program is distributed in the hope that it will be useful,// but WITHOUT ANY WARRANTY; without even the implied warranty of// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the// GNU General Public License for more details.// // You should have received a copy of the GNU General Public License// along with this program; if not, write to the Free Software// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.// /////////////////////////////////////////////////////////////////  Author : Olivier Debon  <odebon@club-internet.fr>//  #include "swf.h"extern unsigned char SQRT[];#define FULL_AA#define PRINT 0typedef unsigned short TYPE;static char cmp8[256];	// 8bit colormaplongallocColor15(Color color){	return (color.red >> 3)<<10 | (color.green>>3)<<5 | (color.blue>>3);}#if 0longallocColor16_646(Color color){	return (color.red >> 2)<<10 | (color.green>>4)<<6 | (color.blue>>2);}#endiflongallocColor16_565(Color color){	return (color.red >> 3)<<11 | (color.green>>2)<<5 | (color.blue>>3);}longallocColor24_32(Color color){	return (color.red)<<16 | (color.green)<<8 | color.blue;}longallocColor8(Color color){	return cmp8[(color.red>>6)<<4 | (color.green>>6)<<2 | (color.blue>>6)];}// PublicGraphicDevice::GraphicDevice(FlashDisplay *fd){	int depth;	flashDisplay = fd;	bgInitialized = 0;	// Reset flash refresh flag	flashDisplay->flash_refresh = 0;        /* 16 bits, RGB565 */	redMask = 0xF800;	greenMask = 0x07E0;	blueMask = 0x001F;        bpp = 2;        depth = 16;        /* should be the actual window size */	targetWidth = fd->width;	targetHeight = fd->height;        bpl = fd->bpl;#if PRINT	printf("Target Width  = %d\n", targetWidth);	printf("Target Height = %d\n", targetHeight);#endif	zoom = FRAC;	movieWidth = targetWidth;	movieHeight = targetHeight;	viewPort.xmin = 0;	viewPort.xmax = targetWidth-1;	viewPort.ymin = 0;	viewPort.ymax = targetHeight-1;	switch (bpp) {		case 1:			allocColor = allocColor8;			redMask = 0xe0;			greenMask = 0x18;			blueMask = 0x07;			break;		case 2:			if (depth == 16) {				allocColor = allocColor16_565;			} else			if (depth == 15) {				allocColor = allocColor15;			}			break;		case 3:		case 4:			allocColor = allocColor24_32;			break;	}	canvasBuffer = (unsigned char *) fd->pixels;	adjust = new Matrix;	foregroundColor.red = 0;	foregroundColor.green = 0;	foregroundColor.blue = 0;	foregroundColor.alpha = ALPHA_OPAQUE;	backgroundColor.red = 0;	backgroundColor.green = 0;	backgroundColor.blue = 0;	backgroundColor.alpha = ALPHA_OPAQUE;	showMore = 0;	setClipping(0);	// Reset	setClipping(1);         /* polygon rasterizer : handle memory errors ! */        height = targetHeight;        segs = (Segment **)malloc(height * sizeof(Segment *));        memset(segs, 0, height * sizeof(Segment *));        ymin = height;        ymax = -1;        seg_pool = (Segment *)malloc(NB_SEGMENT_MAX * sizeof(Segment));        seg_pool_cur = seg_pool;}GraphicDevice::~GraphicDevice(){    free(segs);    free(seg_pool);        if (adjust) {        delete adjust;    }}///////////// PLATFORM INDEPENDENTColor *GraphicDevice::getColormap(Color *old, long n, Cxform *cxform){	Color *newCmp;	newCmp = new Color[n];	if (newCmp == NULL) return NULL;	if (cxform) {		for(long i = 0; i < n; i++)		{			newCmp[i] = cxform->getColor(old[i]);			newCmp[i].pixel = allocColor(newCmp[i]);		}	} else {		for(long i = 0; i < n; i++)		{			newCmp[i].pixel = allocColor(old[i]);		}	}	return newCmp;}///////////// PLATFORM INDEPENDENTlongGraphicDevice::getHeight(){	return targetHeight;}///////////// PLATFORM INDEPENDENTlongGraphicDevice::getWidth(){	return targetWidth;}///////////// PLATFORM INDEPENDENTColorGraphicDevice::getForegroundColor(){	return foregroundColor;}voidGraphicDevice::setForegroundColor(Color color){	foregroundColor = color;}///////////// PLATFORM INDEPENDENTColorGraphicDevice::getBackgroundColor(){	return backgroundColor;}///////////// PLATFORM INDEPENDENTintGraphicDevice::setBackgroundColor(Color color){	if (bgInitialized == 0) {		backgroundColor = color;		clearCanvas();		bgInitialized = 1;		return 1;	}	return 0;}///////////// PLATFORM INDEPENDENTvoidGraphicDevice::setMovieDimension(long width, long height){	float xAdjust, yAdjust;	movieWidth = width;	movieHeight = height;	xAdjust = (float)targetWidth*zoom/(float)width;	yAdjust = (float)targetHeight*zoom/(float)height;	if (xAdjust < yAdjust) {		adjust->a = xAdjust;		adjust->d = xAdjust;                adjust->ty = ((targetHeight*zoom) - (long)(height * xAdjust))/2;		viewPort.ymin = adjust->ty/zoom;		viewPort.ymax = targetHeight-viewPort.ymin-1;	} else {		adjust->a = yAdjust;		adjust->d = yAdjust;                adjust->tx = ((targetWidth*zoom) - (long)(width * yAdjust))/2;		viewPort.xmin = adjust->tx/zoom;		viewPort.xmax = targetWidth-viewPort.xmin-1;	}	if (viewPort.xmin < 0) viewPort.xmin = 0;	if (viewPort.ymin < 0) viewPort.ymin = 0;	if (viewPort.xmax >= targetWidth) viewPort.xmax = targetWidth-1;	if (viewPort.ymax >= targetHeight) viewPort.ymax = targetHeight-1;}///////////// PLATFORM INDEPENDENTvoidGraphicDevice::setMovieZoom(int z){	z *= FRAC;	if (z <= 0 || z > 100) return;	zoom = z;	setMovieDimension(movieWidth,movieHeight);}///////////// PLATFORM INDEPENDENTvoidGraphicDevice::setMovieOffset(long x, long y){	adjust->tx = -zoom*x;	adjust->ty = -zoom*y;}///////////// PLATFORM INDEPENDENTvoidGraphicDevice::clearCanvas(){    TYPE  pixel;    TYPE *point,*p;    long                 h, w,n;    if (!bgInitialized) return;    pixel = allocColor(backgroundColor);    point = (TYPE *)(canvasBuffer + clip_rect.ymin * bpl) + clip_rect.xmin;    w = clip_rect.xmax - clip_rect.xmin;    h = clip_rect.ymax - clip_rect.ymin;    while (h--) {        p = point;        n = w;        while (n--) {            *p++ = pixel;        }        point = (TYPE *)((char *)point + bpl);    }    flashDisplay->flash_refresh = 1;    flashDisplay->clip_x = clip_rect.xmin;    flashDisplay->clip_y = clip_rect.ymin;    flashDisplay->clip_width  = clip_rect.xmax-clip_rect.xmin;    flashDisplay->clip_height = clip_rect.ymax-clip_rect.ymin;}///////////// PLATFORM INDEPENDENTlongGraphicDevice::clip(long &y, long &start, long &end){    long xmin,xend;    if (y < clip_rect.ymin ||        y >= clip_rect.ymax) return 1;    if (end <= start)        return 1;    xmin = clip_rect.xmin * FRAC;    xend = clip_rect.xmax * FRAC;    if (end <= xmin || start >= xend) return 1;    if (start < xmin) start = xmin;    if (end > xend) end = xend;    return 0;}#define RED_MASK   0xF800#define GREEN_MASK 0x07E0#define BLUE_MASK  0x001F/* alpha = 0 : select c1, alpha = 255 select c2 */static inline unsigned longmix_alpha(unsigned long c1,                                       unsigned long c2, int alpha){	long r1,r2,r;	long g1,g2,g;	long b1,b2,b;	r1 = c1 & RED_MASK;	r2 = c2 & RED_MASK;	r = (((r2-r1)*alpha + r1 * 256) >> 8) & RED_MASK;	g1 = c1 & GREEN_MASK;	g2 = c2 & GREEN_MASK;	g = (((g2-g1)*alpha + g1 * 256) >> 8) & GREEN_MASK;	b1 = c1 & BLUE_MASK;	b2 = c2 & BLUE_MASK;	b = (((b2-b1)*alpha + b1 * 256) >> 8) & BLUE_MASK;	return (r|g|b);}voidGraphicDevice::fillLineAA(FillStyleDef *f, long y, long start, long end){    register long   n;    TYPE *line;    TYPE *point,pixel;    unsigned int alpha, start_alpha,end_alpha;        if (clip(y,start,end)) return;        line = (TYPE *)(canvasBuffer + bpl*y);        alpha = f->color.alpha;    pixel = f->color.pixel;        if (alpha == ALPHA_OPAQUE) {        start_alpha = 255 - ((start & (FRAC-1)) << (8-FRAC_BITS));        end_alpha = (end & (FRAC-1)) << (8-FRAC_BITS);                start >>= FRAC_BITS;        end >>= FRAC_BITS;                point = &line[start];        if (start == end) {            *point = mix_alpha(*point, pixel, start_alpha + end_alpha - 255);        } else {            n = end-start;            if (start_alpha < 255) {                *point = mix_alpha(*point, pixel, start_alpha);                point++;                n--;            }            while (n > 0) {                *point = pixel;                point++;                n--;            }            if (end_alpha > 0) {                *point = mix_alpha(*point, pixel, end_alpha);            }        }    } else {        start_alpha = 255 - ((start & (FRAC-1)) << (8-FRAC_BITS));        end_alpha = (end & (FRAC-1)) << (8-FRAC_BITS);        start >>= FRAC_BITS;        end >>= FRAC_BITS;                point = &line[start];                if (start == end) {            *point = mix_alpha(*point, pixel,                                ((start_alpha + end_alpha - 255) * alpha) >> 8);        } else {            n = end-start;            if (start_alpha < 255) {                *point = mix_alpha(*point, pixel, (start_alpha * alpha) >> 8);                point++;                n--;            }            while (n > 0) {                *point = mix_alpha(*point, pixel, alpha);                point++;                n--;            }            if (end_alpha > 0) {                *point = mix_alpha(*point, pixel, (end_alpha * alpha) >> 8);            }        }    }}voidGraphicDevice::fillLine(FillStyleDef *f, long y, long start, long end){	register long   n;        TYPE *line,*point;        TYPE pixel;        unsigned int alpha;	if (clip(y,start,end)) return;        start >>= FRAC_BITS;        end >>= FRAC_BITS;	line = (TYPE *)(canvasBuffer + bpl*y);	point = &line[start];				n = end-start;				        pixel = f->color.pixel;        alpha = f->color.alpha;        if (alpha == ALPHA_OPAQUE) {            while (n--) { 		*point = pixel;		point++;			            }        } else {            while (n--) { 		*point = mix_alpha(*point, pixel, alpha);		point++;			            }        }}/* 16 bit assumed... easy to change */voidGraphicDevice::fillLineBitmap(FillStyleDef *f, long y, long start, long end){    int n;    long x1,y1,dx,dy;    Matrix *m = &f->bitmap_matrix;    Bitmap *b = f->bitmap;    unsigned char *pixels;    TYPE *p;    Color *cmap;    long pixbpl;    TYPE pixel;    int offset;    unsigned char *alpha_table;    /* safety test) */    if (!b) return;    if (clip(y,start,end)) return;        start /= FRAC;    end /= FRAC;    n = end - start;    p = (TYPE *) (this->canvasBuffer + this->bpl*y + start * 2);        /* the coordinates in the image are normalized to 16 bits */    x1 = (long) (m->a * start + m->b * y + m->tx);    y1 = (long) (m->c * start + m->d * y + m->ty);    dx = (long) (m->a);    dy = (long) (m->c);        pixels = b->pixels;    pixbpl = b->bpl;    cmap = f->cmap;    if (b->alpha_buf == NULL) {        while (n) {            if (x1 >= 0 && y1 >= 0 &&                 (x1 >> 16) < b->width && (y1 >> 16) < b->height) {                                pixel = cmap[pixels[(y1 >> 16) * pixbpl + (x1 >> 16)]].pixel;                *p = pixel;            }            x1 += dx;            y1 += dy;            p++;            n--;        }    } else if (f->alpha_table) {        alpha_table = f->alpha_table;        while (n) {            if (x1 >= 0 && y1 >= 0 &&                 (x1 >> 16) < b->width && (y1 >> 16) < b->height) {                                offset = (y1 >> 16) * pixbpl + (x1 >> 16);                pixel = cmap[pixels[offset]].pixel;                *p = mix_alpha(*p, pixel, alpha_table[b->alpha_buf[offset]]);            }            x1 += dx;            y1 += dy;            p++;            n--;        }    } else {        while (n) {            if (x1 >= 0 && y1 >= 0 &&                 (x1 >> 16) < b->width && (y1 >> 16) < b->height) {                                offset = (y1 >> 16) * pixbpl + (x1 >> 16);                pixel = cmap[pixels[offset]].pixel;                *p = mix_alpha(*p, pixel, b->alpha_buf[offset]);            }            x1 += dx;            y1 += dy;            p++;            n--;        }    }}voidGraphicDevice::fillLineLG(Gradient *grad, long y, long start, long end){	long dr,r,v,r2;	register long n;	TYPE *line;	TYPE *point;        Color *cp,*ramp;        Matrix *m = &grad->imat;        unsigned int start_alpha,end_alpha;	if (clip(y,start,end)) return;        start_alpha = 255 - ((start & (FRAC-1)) << (8-FRAC_BITS));        end_alpha = (end & (FRAC-1)) << (8-FRAC_BITS);        	start /= FRAC;	end /= FRAC;	n = end-start;        r = (long) (m->a * start + m->b * y + m->tx);        dr = (long) (m->a);        ramp = grad->ramp;        line = (TYPE *)(canvasBuffer + bpl*y);	point = &line[start];	        r2 = r + n * dr;        if ( ((r | r2) & ~255) == 0 ) {            if (!grad->has_alpha) {#ifdef FULL_AA		if (start_alpha < 255) {                    v = r>>16;                    *point = mix_alpha(*point, (TYPE)ramp[v].pixel, start_alpha);                    point++;                    r += dr;		    n--;		}#endif /* FULL_AA */                while (n>0) {                    v = r>>16;                    *point = (TYPE)ramp[v].pixel;	                    point++;				                    r += dr;						    n--;                }#ifdef FULL_AA		if (end_alpha > 0) {                    v = r>>16;                    *point = mix_alpha(*point, (TYPE)ramp[v].pixel, end_alpha);		}#endif /* FULL_AA */            } else {                while (n--) {                    v = r>>16;                    cp = &ramp[v];                    *point = mix_alpha(*point, cp->pixel, cp->alpha);                    point++;                    r += dr;                }            }        } else {            if (!grad->has_alpha) {#ifdef FULL_AA		if (start_alpha < 255) {                    v = r>>16;                    if (v < 0) v = 0;                    else if (v > 255) v = 255;                    *point = mix_alpha(*point, (TYPE)ramp[v].pixel, start_alpha);                    point++;                    r += dr;		    n--;		}#endif /* FULL_AA */                while (n>0) {                    v = r>>16;                    if (v < 0) v = 0;                    else if (v > 255) v = 255;                    *point = (TYPE)ramp[v].pixel;	                    point++;				                    r += dr;						    n--;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
99精品热视频| 欧美色涩在线第一页| 亚洲精品一卡二卡| 日韩免费性生活视频播放| 91在线视频18| 麻豆国产一区二区| 亚洲国产欧美在线人成| 久久久高清一区二区三区| 这里只有精品免费| 91亚洲男人天堂| 国产成人免费高清| 秋霞电影一区二区| 亚洲综合在线五月| 国产日韩精品一区二区三区在线| 91精品国产黑色紧身裤美女| 99久久精品费精品国产一区二区| 老司机一区二区| 亚洲成在线观看| 亚洲美女屁股眼交3| 久久夜色精品国产欧美乱极品| 欧美午夜理伦三级在线观看| 成人午夜私人影院| 国产在线播放一区二区三区| 午夜视频在线观看一区二区| 日韩美女视频19| 国产偷国产偷亚洲高清人白洁| 欧美一级生活片| www国产成人| 欧美一区二区三区视频在线| 99精品国产热久久91蜜凸| 国产精品天美传媒| 26uuu精品一区二区| 日韩欧美中文字幕一区| 欧美午夜免费电影| 欧美性猛交一区二区三区精品| av在线免费不卡| 99在线热播精品免费| 不卡的电影网站| 不卡一区二区在线| 成人涩涩免费视频| 91在线你懂得| 欧美亚洲一区二区在线| 91在线精品秘密一区二区| 99re亚洲国产精品| 99久久精品国产导航| 在线亚洲一区二区| 91国模大尺度私拍在线视频| 日本高清不卡一区| 在线观看国产日韩| 欧美电影在哪看比较好| 欧美精品免费视频| 日韩欧美不卡在线观看视频| 日韩视频在线你懂得| 精品对白一区国产伦| 久久先锋影音av| 国产精品第四页| 亚洲免费伊人电影| 亚洲一区在线观看视频| 亚洲国产精品天堂| 精品夜夜嗨av一区二区三区| 精品一区二区免费视频| 国产成人亚洲综合a∨婷婷图片| 丁香天五香天堂综合| 色哟哟精品一区| 欧美日韩一区二区在线视频| 日韩欧美在线综合网| 久久综合久久综合久久综合| 亚洲欧洲日产国码二区| 亚洲精品日韩一| 麻豆一区二区三| 国产99精品在线观看| 91黄视频在线观看| 欧美一区二区性放荡片| 国产亚洲欧美激情| 亚洲高清免费一级二级三级| 久久99国产精品尤物| 成人激情综合网站| 欧美日韩电影一区| 久久久久久久久久久电影| 亚洲人吸女人奶水| 免费在线观看日韩欧美| 成人午夜电影久久影院| 欧美日韩国产一级片| 亚洲精品在线观看网站| 亚洲免费看黄网站| 激情综合一区二区三区| 91视频免费观看| 精品国产一区二区在线观看| 亚洲人成网站精品片在线观看| 日韩av高清在线观看| 成人午夜免费电影| 欧美一级久久久| 日韩一区在线看| 免费人成精品欧美精品| 99re热视频精品| 精品少妇一区二区三区视频免付费 | 99精品热视频| 欧美精品一区二区精品网| 亚洲精品亚洲人成人网 | 色综合色狠狠综合色| 日韩一区二区三区av| 一区二区在线免费观看| 国产一区美女在线| 欧美精品1区2区| 综合精品久久久| 国产成人免费xxxxxxxx| 日韩一卡二卡三卡国产欧美| 一区二区三区欧美日| 懂色av一区二区三区免费看| 精品久久国产字幕高潮| 亚洲一区视频在线观看视频| 成人av免费在线播放| 欧美成人在线直播| 日韩成人午夜电影| 在线观看欧美日本| 国产精品久久久久久亚洲毛片| 蜜臀av一区二区在线观看 | 国产欧美日韩麻豆91| 毛片一区二区三区| 欧美精品久久久久久久多人混战| 亚洲三级理论片| 国产成人免费xxxxxxxx| 久久综合狠狠综合| 蓝色福利精品导航| 欧美一区二区三区免费大片| 亚洲影视资源网| 日本久久精品电影| 亚洲情趣在线观看| 99久久精品一区二区| 欧美激情综合在线| 国产丶欧美丶日本不卡视频| 亚洲精品一线二线三线| 久久草av在线| 日韩视频一区二区三区在线播放| 视频一区二区三区在线| 欧美日韩精品欧美日韩精品一 | 国产女人18毛片水真多成人如厕 | 制服丝袜中文字幕亚洲| 亚洲二区在线视频| 欧美精品乱人伦久久久久久| 亚洲sss视频在线视频| 欧美日韩一区在线| 丝袜美腿一区二区三区| 日韩一区二区在线免费观看| 日韩中文字幕亚洲一区二区va在线 | 欧美电影免费观看高清完整版在线 | 日本高清不卡视频| 亚洲午夜精品17c| 欧美蜜桃一区二区三区| 午夜一区二区三区视频| 91精品国产色综合久久不卡蜜臀| 日韩精品1区2区3区| 日韩一区二区三区免费观看| 精品在线免费视频| 国产亚洲欧美色| 99久久夜色精品国产网站| 亚洲婷婷综合久久一本伊一区| 色婷婷精品久久二区二区蜜臂av| 亚洲激情六月丁香| 777久久久精品| 精品一区二区三区视频在线观看 | 成人免费毛片a| 亚洲欧美另类图片小说| 欧美日韩aaa| 国产原创一区二区三区| 国产精品的网站| 欧美日韩精品免费观看视频| 激情丁香综合五月| 亚洲同性同志一二三专区| 欧美精品自拍偷拍| 国产精品1区2区| 亚洲综合色婷婷| 日韩精品影音先锋| av一区二区三区黑人| 亚洲第一福利一区| 国产偷国产偷精品高清尤物| 91成人网在线| 久草精品在线观看| 夜夜亚洲天天久久| 日韩精品一区二区三区中文不卡 | 99久久久久免费精品国产| 亚洲第一福利一区| 国产色婷婷亚洲99精品小说| 91日韩一区二区三区| 国产一区二区三区免费播放 | 一区二区三区四区精品在线视频 | 亚洲免费成人av| 欧美mv日韩mv国产网站app| 色偷偷久久人人79超碰人人澡| 日本免费在线视频不卡一不卡二| 亚洲国产精品v| 在线不卡欧美精品一区二区三区| 成人一区二区三区中文字幕| 亚洲伊人伊色伊影伊综合网| 国产日韩综合av| 欧美日韩极品在线观看一区| 成人禁用看黄a在线| 老司机精品视频在线| 亚洲一区二区三区激情| 国产精品欧美一级免费|