BITMAPINFOHEADER::biClrUsed值,在某些APP(如光大)中需要指定用以表明调色板颜色数量
This commit is contained in:
parent
bfb5c45029
commit
fcd6ea9121
|
@ -469,6 +469,7 @@ std::string scanned_img::file_header(SANE_ImageType type, float resolution)
|
||||||
pal_size = 2 * sizeof(int);
|
pal_size = 2 * sizeof(int);
|
||||||
else if (bih.biBitCount == 8)
|
else if (bih.biBitCount == 8)
|
||||||
pal_size = 256 * sizeof(int);
|
pal_size = 256 * sizeof(int);
|
||||||
|
bih.biClrUsed = pal_size / sizeof(int); // some APP (PJScanner.exe 光大……) use this field to calculate pallete
|
||||||
|
|
||||||
{
|
{
|
||||||
BITMAPFILEHEADER fh = { 0 };
|
BITMAPFILEHEADER fh = { 0 };
|
||||||
|
|
Loading…
Reference in New Issue