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

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

?? native.c

?? mini gui 1.6.8 lib and source
?? C
?? 第 1 頁 / 共 3 頁
字號:
        return RGB2PIXEL555 (color->r, color->g, color->b);    case 16:        return RGB2PIXEL565 (color->r, color->g, color->b);    case 24:    case 32:        return RGB2PIXEL888 (color->r, color->g, color->b);    }    return -1;}static int unmappixel (GAL_GC gc, gal_pixel pixel, GAL_Color* color){    switch (gc.psd->bpp) {    case 1:        if (pixel) {            color->r = 255;            color->g = 255;            color->b = 255;        }        else {            color->r = 0;            color->g = 0;            color->b = 0;        }        break;    case 2:    case 4:        color->r = SysPixelColor [pixel].r;        color->g = SysPixelColor [pixel].g;        color->b = SysPixelColor [pixel].b;        break;    case 8:        color->r = PIXEL332RED (pixel) << 5;        color->g = PIXEL332GREEN (pixel) << 5;        color->b = PIXEL332BLUE (pixel) << 6;        break;    case 15:        color->r = PIXEL555RED (pixel) << 3;        color->g = PIXEL555GREEN (pixel) << 3;        color->b = PIXEL555BLUE (pixel) << 3;        break;    case 16:        color->r = PIXEL565RED (pixel) << 3;        color->g = PIXEL565GREEN (pixel) << 2;        color->b = PIXEL565BLUE (pixel) << 3;        break;    case 24:    case 32:        color->r = PIXEL888RED (pixel);        color->g = PIXEL888GREEN (pixel);        color->b = PIXEL888BLUE (pixel);        break;    }        return 0;}/* * Palette operations */static int getpalette (GAL_GC gc, int s, int len, GAL_Color* cmap){    gc.psd->GetPalette(gc.psd,s,len,cmap);    return 0;}static int setpalette (GAL_GC gc, int s, int len, GAL_Color* cmap){    gc.psd->SetPalette(gc.psd,s,len,cmap);    return 0;}/* * Specical functions work for <=8 bit color mode. */static int setcolorfulpalette (GAL_GC gc){    int i;    GAL_Color pal[256];    if (gc.psd->bpp > 8)    return 0;    switch ( gc.psd->bpp ) {    case 1:        for (i = 0; i < 2; i++) {            pal[i].b = SysPixelColor[i*15].b;            pal[i].g = SysPixelColor[i*15].g;            pal[i].r = SysPixelColor[i*15].r;            pal[i].a = 0;        }        gc.psd->SetPalette(gc.psd,0,2,pal);        break;    case 2:        for (i = 0; i < 4; i++) {            pal[i].b = SysPixelColor[i*4].b;            pal[i].g = SysPixelColor[i*4].g;            pal[i].r = SysPixelColor[i*4].r;            pal[i].a = 0;        }        gc.psd->SetPalette(gc.psd,0,4,pal);        break;    case 4:        for (i = 0; i < 16; i++) {            pal[i].b = SysPixelColor[i].b;            pal[i].g = SysPixelColor[i].g;            pal[i].r = SysPixelColor[i].r;            pal[i].a = 0;        }        gc.psd->SetPalette(gc.psd,0,16,pal);            break;    case 8:        for (i = 0; i < 256; i++) {#if 1            pal[i].r = PIXEL332RED (i) << 5;            pal[i].g = PIXEL332GREEN (i) << 5;            pal[i].b = PIXEL332BLUE (i) << 6;#else            pal[i].b = (i & 7) * (64 / 2);        /* 3 bits */            pal[i].g = ((i & 56) >> 3) * (64 / 2);    /* 3 bits */            pal[i].r = ((i & 192) >> 6) * (64);        /* 2 bits */#endif            pal[i].a = 0;        }        gc.psd->SetPalette (gc.psd, 0, 256, pal);            break;    default:        break;    }            return 0;}/* * Box operations * TODO: Currently we did not do clpping in putbox() or getbox() or other. * If we do clipping at early, we can spend time... */static size_t boxsize (GAL_GC gc, int w, int h){    if ((w <= 0) || (h <= 0)) return -1;    return w * h * bytesperpixel (gc);}static int fillbox (GAL_GC gc, int x, int y, int w, int h, gal_pixel pixel){    if ((w <= 0) || (h <= 0)) return -1;    BLOCK_DRAW_SEM;    if (_COOR_TRANS && gc.psd == __mg_cur_gfx->phygc.psd)        rotaterect (&x, &y, &w, &h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);    if (native_gen_clipbox (gc.psd, &x, &y, &w, &h) == CLIP_INVISIBLE)        goto ret;    gc.psd->FillRect (gc.psd, x, y, w, h, pixel) ;    if (gc.psd->UpdateRect) gc.psd->UpdateRect (gc.psd, x, y, x + w, y + h);ret:    UNBLOCK_DRAW_SEM;    return 0;}static void putbox_helper (GAL_GC gc, int x, int y, int w, int h, void* buf, int pitch){    int bpp = bytesperpixel (gc);    gal_uint8 *tmpptr= (gal_uint8*) buf;    rotaterect (&x, &y, &w, &h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?1:0);    if ( y < 0 ) {        h += y;        tmpptr -= y * pitch;        y = 0;    }    if ( x < 0 ) {        w += x;        tmpptr -= bpp * x;        x = 0;    }    if ( x + w -1 >= gc.psd->yres)         w = gc.psd->yres - x;    if ( y + h -1 >= gc.psd->xres)         h = gc.psd->xres - y;    rotatepoint (&x, &y, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);    if (_ROT_DIR_CW) {        while (h > 0) {            gc.psd->PutBox (gc.psd, x, y, 1, w, tmpptr);            tmpptr += pitch;            x--;            h--;        }    }    else {        //char* reversi = alloca (w * bpp);        char* reversi = malloc (w * bpp);        y -= w - 1;        while (h > 0) {            reverse_buff (reversi, tmpptr, w, bpp);            gc.psd->PutBox (gc.psd, x, y, 1, w, reversi);            tmpptr += pitch;            x++;            h--;        }        free (reversi);    }}static int putbox_wrapper (GAL_GC gc, int x, int y, int w, int h, void* buf, int pitch){    if ((w <= 0) || (h <= 0)) return -1;        BLOCK_DRAW_SEM;    if (_COOR_TRANS && gc.psd == __mg_cur_gfx->phygc.psd) {        rotaterect (&x, &y, &w, &h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);        if (gc.psd->doclip) {            if ((x + w - 1 < gc.psd->clipminx) || (x >= gc.psd->clipmaxx))                goto inv_args;            if ((y + h - 1 < gc.psd->clipminy) || (y >= gc.psd->clipmaxy))                goto inv_args;        } else {            if ((x + w - 1 < 0) || (x >= gc.psd->xres))                goto inv_args;            if ((y + h - 1 < 0) || (y >= gc.psd->yres))                goto inv_args;        }        putbox_helper (gc, x, y, w, h, buf, pitch);    }    else {        if (gc.psd->doclip) {            if ((x + w - 1 < gc.psd->clipminx) || (x >= gc.psd->clipmaxx))                goto inv_args;            if ((y + h - 1 < gc.psd->clipminy) || (y >= gc.psd->clipmaxy))                goto inv_args;        } else {            if ((x + w - 1 < 0) || (x >= gc.psd->xres))                goto inv_args;            if ((y + h - 1 < 0) || (y >= gc.psd->yres))                goto inv_args;        }        gc.psd->PutBox (gc.psd, x, y, w, h, buf);   /* ignore pitch */    }    if (gc.psd->UpdateRect) gc.psd->UpdateRect (gc.psd, x, y, x + w, y + h);inv_args:    UNBLOCK_DRAW_SEM;    return 0;}static int putbox (GAL_GC gc, int x, int y, int w, int h, void* buf){    return putbox_wrapper (gc, x, y, w, h, buf, w * bytesperpixel (gc));}static int putboxmask ( GAL_GC gc, int x, int y, int w, int h, void* buf, gal_pixel cxx){    int oldw = w, bpp = 0;    gal_uint8 *tmpptr= (gal_uint8*) buf;    if ((w <= 0) || (h <= 0)) return -1;    BLOCK_DRAW_SEM;    if (_COOR_TRANS && gc.psd == __mg_cur_gfx->phygc.psd) {        rotaterect (&x, &y, &w, &h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);        if (gc.psd->doclip) {            if ((x + w - 1 < gc.psd->clipminx) || (x >= gc.psd->clipmaxx))                goto inv_args;            if ((y + h - 1 < gc.psd->clipminy) || (y >= gc.psd->clipmaxy))                goto inv_args;        } else {            if ((x + w - 1 < 0) || (x >= gc.psd->xres))                goto inv_args;            if ((y + h - 1 < 0) || (y >= gc.psd->yres))                goto inv_args;        }        rotaterect (&x, &y, &w, &h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?1:0);        bpp = bytesperpixel (gc);        if ( y < 0 ) {            h += y;            tmpptr -= y * bpp * w;            y = 0;        }        if ( x < 0 ) {            w += x;            tmpptr -= bpp * x;            x = 0;        }                if ( x + w -1 >= gc.psd->yres)             w = gc.psd->yres - x ;        if ( y + h -1 >= gc.psd->xres)             h = gc.psd->xres - y ;        rotatepoint (&x, &y, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);        if (_ROT_DIR_CW) {            while (h > 0) {                gc.psd->PutBoxMask (gc.psd, x, y, 1, w, tmpptr, cxx);                    tmpptr += bpp * oldw;                x--;                h--;            }        }        else {            //char* reversi = alloca (w * bpp);            char* reversi = malloc (w * bpp);                y -= w - 1;            while (h > 0) {                reverse_buff (reversi, tmpptr, w, bpp);                gc.psd->PutBoxMask (gc.psd, x, y, 1, w, reversi, cxx);                    tmpptr += bpp * oldw;                x++;                h--;            }            free (reversi);        }    }    else {        if (gc.psd->doclip) {            if ((x + w - 1 < gc.psd->clipminx) || (x >= gc.psd->clipmaxx))                goto inv_args;            if ((y + h - 1 < gc.psd->clipminy) || (y >= gc.psd->clipmaxy))                goto inv_args;        } else {            if ((x + w - 1 < 0) || (x >= gc.psd->xres))                goto inv_args;            if ((y + h - 1 < 0) || (y >= gc.psd->yres))                goto inv_args;        }        gc.psd->PutBoxMask (gc.psd, x, y, w, h, buf, cxx);    }    if (gc.psd->UpdateRect) gc.psd->UpdateRect (gc.psd, x, y, x + w, y + h);inv_args:    UNBLOCK_DRAW_SEM;    return 0;}static void getbox_helper (GAL_GC gc, int x, int y, int w, int h, void* buf, int pitch){    int bpp = bytesperpixel (gc);    gal_uint8 *tmpptr= (gal_uint8*) buf;    if ( y < 0 ) {        h += y;        tmpptr -= y * pitch;        y = 0;    }    if ( x < 0 ) {        w += x;        tmpptr -= bpp * x;        x = 0;    }            if ( x + w -1 >= gc.psd->yres)         w = gc.psd->yres - x ;    if ( y + h -1 >= gc.psd->xres)         h = gc.psd->xres - y ;    rotatepoint (&x, &y, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);    if (_ROT_DIR_CW) {        while (h > 0) {            gc.psd->GetBox (gc.psd, x, y, 1, w, tmpptr);            tmpptr += pitch;            x--;            h--;        }    }    else {        //char* reversi = alloca (w * bpp);        char* reversi = malloc (w * bpp);        y -= w - 1;        while (h > 0) {            gc.psd->GetBox (gc.psd, x, y, 1, w, reversi);            reverse_buff (tmpptr, reversi, w, bpp);            tmpptr += pitch;            x++;            h--;        }        free (reversi);    }}static int getbox_wrapper (GAL_GC gc, int x, int y, int w, int h, void* buf, int pitch){    if ((w <= 0) || (h <= 0)) return -1;    if (_COOR_TRANS && gc.psd == __mg_cur_gfx->phygc.psd) {        if ((x + w - 1 < 0) || (x >= gc.psd->yres))            return -1;        if ((y + h - 1 < 0) || (y >= gc.psd->xres))            return -1;        getbox_helper (gc, x, y, w, h, buf, pitch);    }    else {        if ((x + w - 1 < 0) || (x >= gc.psd->xres))            return -1;        if ((y + h - 1 < 0) || (y >= gc.psd->yres))            return -1;        gc.psd->GetBox (gc.psd, x, y, w, h, buf);   /* ignore pitch */    }    return 0;}static int getbox (GAL_GC gc, int x, int y, int w, int h, void* buf){    return getbox_wrapper (gc, x, y, w, h, buf, w * bytesperpixel (gc));}static int scalebox (GAL_GC gc, int sw, int sh, void* srcbuf,        int dw, int dh, void* dstbuf){    return native_gen_scalebox (gc.psd, sw, sh, srcbuf, dw, dh, dstbuf);}static int copybox (GAL_GC gc, int x, int y, int w, int h, int nx, int ny){    int org_w = w, org_h = h;    if ((w <= 0) || (h <= 0)) return -1;    if (_COOR_TRANS && gc.psd == __mg_cur_gfx->phygc.psd) {        rotaterect (&x, &y, &w, &h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);        rotaterect (&nx, &ny, &org_w, &org_h, _ROT_DIR_CW?gc.psd->xres:gc.psd->yres, _ROT_DIR_CW?0:1);    }    if ((x >= gc.psd->xres) || (x + w - 1 < 0)) return -1;    if ((y >= gc.psd->yres) || (y + h - 1 < 0)) return -1;    if (x < 0) { nx -= x; w += x; x = 0; }    if (y < 0) { ny -= y; h += y; y = 0; }    if (x + w - 1 >= gc.psd->xres) w = gc.psd->xres - x;    if (y + h - 1 >= gc.psd->yres) h = gc.psd->yres - y;            BLOCK_DRAW_SEM;    //dst do clip    if (gc.psd->doclip) {        if ((nx + w - 1 < gc.psd->clipminx) || (nx >= gc.psd->clipmaxx))            goto inv_args;        if ((ny + h - 1 < gc.psd->clipminy) || (ny >= gc.psd->clipmaxy))            goto inv_args;        if (nx < gc.psd->clipminx) {            x += gc.psd->clipminx - nx;            w -= gc.psd->clipminx - nx;            nx = gc.psd->clipminx;        }         if (nx + w - 1 >= gc.psd->clipmaxx) {            w = gc.psd->clipmaxx - nx;        }        if (ny < gc.psd->clipminy) {            y += gc.psd->clipminy - ny;            h -= gc.psd->clipminy - ny;            ny = gc.psd->clipminy;        }        if (ny + h - 1 >= gc.psd->clipmaxy) {            h = gc.psd->clipmaxy - ny;        }    

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美日韩高清一区二区| 婷婷成人激情在线网| 欧美一区二区三区视频在线观看 | 91久久精品国产91性色tv| 国内国产精品久久| 久久99蜜桃精品| 久久综合综合久久综合| 麻豆精品一区二区综合av| 日韩在线观看一区二区| 三级不卡在线观看| 麻豆国产精品777777在线| 麻豆国产91在线播放| 蜜桃91丨九色丨蝌蚪91桃色| 激情综合五月天| 国产成人亚洲精品青草天美| 国产成人av电影免费在线观看| 国产成人夜色高潮福利影视| 福利一区二区在线观看| 北条麻妃国产九九精品视频| 99视频精品免费视频| 色呦呦国产精品| 欧美一区中文字幕| 2014亚洲片线观看视频免费| 中文一区二区完整视频在线观看| 中文字幕亚洲在| 夜夜嗨av一区二区三区中文字幕| 天天亚洲美女在线视频| 国精产品一区一区三区mba桃花 | 亚洲天堂2016| 奇米亚洲午夜久久精品| 国产精品18久久久久久久久久久久 | 欧美吻胸吃奶大尺度电影 | 日韩欧美一区二区三区在线| 久久精品一区八戒影视| 一区二区三区中文在线| 看电影不卡的网站| 精品一区二区三区免费播放| 成人aaaa免费全部观看| 欧美精品乱人伦久久久久久| 久久品道一品道久久精品| 亚洲欧美成aⅴ人在线观看| 日韩成人精品在线| 99亚偷拍自图区亚洲| 日韩欧美123| 18涩涩午夜精品.www| 蜜桃久久精品一区二区| 日本韩国欧美一区| 久久久天堂av| 热久久免费视频| 97久久精品人人澡人人爽| 在线电影一区二区三区| 国产精品久久久久7777按摩| 另类小说综合欧美亚洲| 欧美亚洲国产一区二区三区va | 亚洲欧美自拍偷拍| 麻豆精品视频在线观看视频| 在线免费亚洲电影| 中文字幕欧美国产| 美腿丝袜亚洲三区| 欧美三级日韩三级| 最新热久久免费视频| 国产不卡视频在线播放| 日韩美一区二区三区| 日韩精品一卡二卡三卡四卡无卡| 99免费精品视频| 国产欧美精品一区二区色综合朱莉| 日韩激情在线观看| 欧美日韩精品一区二区三区四区| 亚洲欧美日韩国产一区二区三区| 国产成人亚洲综合a∨婷婷| 欧美videos中文字幕| 日本麻豆一区二区三区视频| 777午夜精品免费视频| 亚洲午夜电影网| 欧美日韩国产美女| 亚洲一区二区成人在线观看| 日本高清不卡一区| 亚洲一区二区三区自拍| 在线观看视频一区二区| 一区二区三区在线免费视频| 色狠狠色狠狠综合| 亚洲成人免费av| 555www色欧美视频| 免费高清视频精品| 欧美白人最猛性xxxxx69交| 美女网站色91| 久久久精品蜜桃| 成人动漫一区二区在线| 亚洲欧美日韩中文字幕一区二区三区| 韩国三级在线一区| 精品国产免费人成电影在线观看四季| 久久99精品久久久久久国产越南| 精品久久久久久久久久久久包黑料| 国内精品不卡在线| 国产精品毛片无遮挡高清| 色婷婷亚洲一区二区三区| 一区二区三区91| 777xxx欧美| 国产福利精品一区二区| 国产精品久久久久久久久久久免费看| av男人天堂一区| 午夜精品久久久久久久蜜桃app| 欧美一区二区三区喷汁尤物| 精品影视av免费| 中文字幕在线一区免费| 欧美视频一二三区| 国产乱码精品一区二区三区忘忧草| 国产精品区一区二区三区| 在线免费观看不卡av| 蜜桃精品视频在线观看| 国产精品久久夜| 欧美日韩日日摸| 成人一区二区三区视频在线观看| 亚洲精品ww久久久久久p站| 欧美丰满嫩嫩电影| 不卡一区二区中文字幕| 免费成人在线视频观看| 国产精品家庭影院| 欧美成人猛片aaaaaaa| 91污在线观看| 精彩视频一区二区| 亚洲综合色自拍一区| 国产亚洲综合av| 欧美日韩mp4| 99免费精品视频| 久久精品国产亚洲aⅴ| 一级日本不卡的影视| 久久久久久久免费视频了| 欧美片网站yy| 91免费在线看| 成人综合婷婷国产精品久久 | 久久久电影一区二区三区| 波多野结衣中文字幕一区| 秋霞电影一区二区| 成人免费在线观看入口| 久久亚洲二区三区| 欧美一区二区三区播放老司机| 99r国产精品| 高清久久久久久| 精品一区二区三区免费视频| 午夜激情久久久| 亚洲成av人片观看| 一区二区三区 在线观看视频| 国产亚洲综合色| 日韩欧美亚洲另类制服综合在线| 91久久精品一区二区| 色综合久久99| 91福利资源站| 欧美视频在线一区| 欧美性猛交一区二区三区精品| 91美女片黄在线观看91美女| 成人免费视频一区| 成人av综合在线| www.亚洲精品| 成人av在线一区二区三区| 国产在线麻豆精品观看| 经典三级在线一区| 经典三级一区二区| 国产91露脸合集magnet| 国产精品中文字幕一区二区三区| 久久精品国产99| 国产精品一级二级三级| 成人av网在线| 一本大道久久a久久综合婷婷| 国产麻豆视频精品| 日韩极品在线观看| 亚洲欧美一区二区三区国产精品| 亚洲精品日日夜夜| 亚洲欧洲国产专区| 国产欧美一区视频| 精品三级在线观看| 免费成人av在线播放| 国产精品中文有码| 久久精品999| 美女视频黄频大全不卡视频在线播放| 亚洲欧美在线观看| 国产精品乱码妇女bbbb| 日韩欧美国产三级| 国产精品盗摄一区二区三区| 亚洲精品一区二区三区蜜桃下载 | 精品国产一区二区三区不卡| 欧美色区777第一页| 色狠狠av一区二区三区| 色吧成人激情小说| 国产成人精品亚洲午夜麻豆| 亚洲一区二区三区视频在线播放| 日韩黄色免费电影| 国产成人高清在线| 久久99精品久久久久婷婷| 日韩中文字幕麻豆| 日韩激情中文字幕| 亚洲欧美日韩在线不卡| 久久福利视频一区二区| 久久99久久精品| 国产高清亚洲一区| 福利视频网站一区二区三区| eeuss鲁片一区二区三区| 午夜精品福利一区二区蜜股av| 日韩精品一级中文字幕精品视频免费观看 | 免费观看一级特黄欧美大片|