kopia lustrzana https://gitlab.com/sane-project/backends
* backend/genesys_devices.c: reduced height of calibration area
* backend/genesys_gl841.c: fixed bug in offset calibration(offset values were not clamped to 0..255)merge-requests/1/head
rodzic
b06eb2220b
commit
6a7fb3235a
|
@ -1,3 +1,9 @@
|
|||
2006-12-10 Pierre Willenbrock <pierre@pirsoft.dnsalias.org>
|
||||
|
||||
* backend/genesys_devices.c: reduced height of calibration area
|
||||
* backend/genesys_gl841.c: fixed bug in offset calibration(offset
|
||||
values were not clamped to 0..255)
|
||||
|
||||
2006-12-10 Ulrich Deiters <ulrich.deiters@uni-koeln.de>
|
||||
|
||||
* canon: disentangled some pointer arithmetics in canon-sane.c
|
||||
|
|
|
@ -478,7 +478,7 @@ static Genesys_Model canon_lide_50_model = {
|
|||
| GENESYS_FLAG_SKIP_WARMUP
|
||||
| GENESYS_FLAG_OFFSET_CALIBRATION
|
||||
| GENESYS_FLAG_DARK_WHITE_CALIBRATION, /* Which flags are needed for this scanner? */
|
||||
300,
|
||||
280,
|
||||
400
|
||||
};
|
||||
|
||||
|
|
|
@ -4362,7 +4362,7 @@ gl841_offset_calibration (Genesys_Device * dev)
|
|||
int turn;
|
||||
char fn[20];
|
||||
SANE_Bool acceptable = SANE_FALSE;
|
||||
int mintgt = 0x600;
|
||||
int mintgt = 0x2000;
|
||||
|
||||
DBG (DBG_proc, "gl841_offset_calibration\n");
|
||||
|
||||
|
@ -4706,6 +4706,10 @@ gl841_offset_calibration (Genesys_Device * dev)
|
|||
off[j] = 0xffff;
|
||||
} else
|
||||
off[j] = -(mintgt * (off1[j] - off2[j]) + min2[j] * off1[j] - min1[j] * off2[j])/(min2[j]-min1[j]);
|
||||
if (off[j] > 255)
|
||||
off[j] = 255;
|
||||
if (off[j] < 0)
|
||||
off[j] = 0;
|
||||
dev->frontend.offset[j] = off[j];
|
||||
}
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue