|
|
| version 1.1, 2004/08/01 05:31:29 | version 1.3, 2008/06/02 20:07:30 |
|---|---|
| Line 70 UINT bmpdata_setinfo(BMPINFO *bi, const | Line 70 UINT bmpdata_setinfo(BMPINFO *bi, const |
| STOREINTELDWORD(bi->biHeight, inf->height); | STOREINTELDWORD(bi->biHeight, inf->height); |
| STOREINTELWORD(bi->biPlanes, 1); | STOREINTELWORD(bi->biPlanes, 1); |
| STOREINTELWORD(bi->biBitCount, inf->bpp); | STOREINTELWORD(bi->biBitCount, inf->bpp); |
| // STOREINTELDWORD(bi->biCompression, BI_RGB); | /* STOREINTELDWORD(bi->biCompression, BI_RGB); */ |
| ret = bmpdata_getdatasize(bi); | ret = bmpdata_getdatasize(bi); |
| STOREINTELDWORD(bi->biSizeImage, ret); | STOREINTELDWORD(bi->biSizeImage, ret); |
| // STOREINTELDWORD(bi->biXPelsPerMeter, 0); | |
| // STOREINTELDWORD(bi->biYPelsPerMeter, 0); | |
| if (inf->bpp <= 8) { | if (inf->bpp <= 8) { |
| tmp = 1 << inf->bpp; | tmp = 1 << inf->bpp; |
| STOREINTELDWORD(bi->biClrUsed, tmp); | STOREINTELDWORD(bi->biClrUsed, tmp); |
| Line 85 bdsi_exit: | Line 83 bdsi_exit: |
| return(ret); | return(ret); |
| } | } |
| BOOL bmpdata_getinfo(const BMPINFO *bi, BMPDATA *inf) { | BRESULT bmpdata_getinfo(const BMPINFO *bi, BMPDATA *inf) { |
| UINT tmp; | UINT tmp; |
| int width; | int width; |
| Line 121 bdgi_err: | Line 119 bdgi_err: |
| return(FAILURE); | return(FAILURE); |
| } | } |
| BYTE *bmpdata_lzx(int level, int dstsize, const BYTE *dat) { | UINT8 *bmpdata_lzx(int level, int dstsize, const UINT8 *dat) { |
| BYTE *ret; | UINT8 *ret; |
| BYTE *ptr; | UINT8 *ptr; |
| BYTE ctrl; | UINT8 ctrl; |
| BYTE bit; | UINT8 bit; |
| UINT mask; | UINT mask; |
| UINT tmp; | UINT tmp; |
| int pos; | int pos; |
| Line 136 BYTE *bmpdata_lzx(int level, int dstsize | Line 134 BYTE *bmpdata_lzx(int level, int dstsize |
| if (dat == NULL) { | if (dat == NULL) { |
| return(NULL); | return(NULL); |
| } | } |
| ret = (BYTE *)_MALLOC(dstsize, "res"); | ret = (UINT8 *)_MALLOC(dstsize, "res"); |
| if (ret == NULL) { | if (ret == NULL) { |
| goto lxz_err; | goto lxz_err; |
| } | } |
| Line 174 lxz_err: | Line 172 lxz_err: |
| return(ret); | return(ret); |
| } | } |
| BYTE *bmpdata_solvedata(const BYTE *dat) { | UINT8 *bmpdata_solvedata(const UINT8 *dat) { |
| int dstsize; | int dstsize; |