From fcd6ea91217da711e5678c9ed47dc3085e6ec633 Mon Sep 17 00:00:00 2001 From: gb <741021719@qq.com> Date: Tue, 26 Dec 2023 17:24:04 +0800 Subject: [PATCH] =?UTF-8?q?BITMAPINFOHEADER::biClrUsed=E5=80=BC=EF=BC=8C?= =?UTF-8?q?=E5=9C=A8=E6=9F=90=E4=BA=9BAPP=EF=BC=88=E5=A6=82=E5=85=89?= =?UTF-8?q?=E5=A4=A7=EF=BC=89=E4=B8=AD=E9=9C=80=E8=A6=81=E6=8C=87=E5=AE=9A?= =?UTF-8?q?=E7=94=A8=E4=BB=A5=E8=A1=A8=E6=98=8E=E8=B0=83=E8=89=B2=E6=9D=BF?= =?UTF-8?q?=E9=A2=9C=E8=89=B2=E6=95=B0=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sane/scanned_img.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/sane/scanned_img.cpp b/sane/scanned_img.cpp index 69e093b..fa4c22a 100644 --- a/sane/scanned_img.cpp +++ b/sane/scanned_img.cpp @@ -469,6 +469,7 @@ std::string scanned_img::file_header(SANE_ImageType type, float resolution) pal_size = 2 * sizeof(int); else if (bih.biBitCount == 8) pal_size = 256 * sizeof(int); + bih.biClrUsed = pal_size / sizeof(int); // some APP (PJScanner.exe ¹â´ó¡­¡­) use this field to calculate pallete { BITMAPFILEHEADER fh = { 0 };