kopia lustrzana https://gitlab.com/sane-project/website
119 wiersze
4.4 KiB
HTML
119 wiersze
4.4 KiB
HTML
<!-- received="Wed Oct 14 20:38:02 1998 PDT" -->
|
|
<!-- sent="Sun, 11 Oct 1998 17:34:51 +0200 (MEST)" -->
|
|
<!-- name="Heiko_Schroeder@t-online.de" -->
|
|
<!-- email="Heiko_Schroeder@t-online.de" -->
|
|
<!-- subject="Patch for MUSTEK scanner driver" -->
|
|
<!-- id="m0zSNWF-0000aKC@rincewind.local.de" -->
|
|
<!-- inreplyto="" -->
|
|
<title>sane-devel: Patch for MUSTEK scanner driver</title>
|
|
<h1>Patch for MUSTEK scanner driver</h1>
|
|
<a href="mailto:Heiko_Schroeder@t-online.de"><i>Heiko_Schroeder@t-online.de</i></a><br>
|
|
<i>Sun, 11 Oct 1998 17:34:51 +0200 (MEST)</i>
|
|
<p>
|
|
<ul>
|
|
<li> <b>Messages sorted by:</b> <a href="date.html#150">[ date ]</a><a href="index.html#150">[ thread ]</a><a href="subject.html#150">[ subject ]</a><a href="author.html#150">[ author ]</a>
|
|
<!-- next="start" -->
|
|
<li> <b>Next message:</b> <a href="0151.html">Lowery, Robert: "AcerScan 610S Support"</a>
|
|
<li> <b>Previous message:</b> <a href="0149.html">the developer: "a couple sco sane questions"</a>
|
|
<!-- nextthread="start" -->
|
|
<!-- reply="end" -->
|
|
</ul>
|
|
<!-- body="start" -->
|
|
---1463811839-1804289383-908120091=:589<br>
|
|
Content-Type: TEXT/plain; CHARSET=US-ASCII<br>
|
|
<p>
|
|
Hi!<br>
|
|
<p>
|
|
When trying sane-0.74 with my old MFS-6000CX scanner, I recognized<br>
|
|
that resolutions above 300dpi don't work. The problem is the way<br>
|
|
this scanner encodes the resolution: For resolutions above 300dpi,<br>
|
|
this scanner wants dpi/2 to be stored in the usual encoding and bit<br>
|
|
7 of byte 4 of the start scan data to be set. (This information comes<br>
|
|
from trial and error, so all I can say is that it works for me...)<br>
|
|
<p>
|
|
The scanner identifies itself as MSF-06000CZ, Rev. 4.0.<br>
|
|
<p>
|
|
Attached is a patch to adapt mustek.c and mustek.h to work with the<br>
|
|
scanner.<br>
|
|
<p>
|
|
CU<br>
|
|
Heiko<br>
|
|
<p>
|
|
<pre>
|
|
--
|
|
+-------------------------------+------------------------------------+
|
|
|Email: | Snail-mail: Heiko Schroeder |
|
|
| | Bremer Strasse 123 |
|
|
| <a href="mailto:Heiko_Schroeder@t-online.de">Heiko_Schroeder@t-online.de</a> | 26382 Wilhelmshaven |
|
|
| | GERMANY |
|
|
+-------------------------------+------------------------------------+
|
|
<p>
|
|
---1463811839-1804289383-908120091=:589
|
|
Content-Type: TEXT/plain; CHARSET=US-ASCII
|
|
Content-Description: mustek.diff
|
|
<p>
|
|
--- mustek.c.orig Sun Oct 11 17:22:34 1998
|
|
+++ mustek.c Sun Oct 11 14:16:40 1998
|
|
@@ -640,7 +640,7 @@
|
|
dev->x_range.max = SANE_FIX (8.5 * MM_PER_INCH);
|
|
dev->y_range.max = SANE_FIX (14.0 * MM_PER_INCH);
|
|
dev->dpi_range.max = SANE_FIX (600);
|
|
- dev->flags |= MUSTEK_FLAG_USE_EIGHTS;
|
|
+ dev->flags |= MUSTEK_FLAG_USE_EIGHTS | MUSTEK_FLAG_DOUBLE_RES;
|
|
}
|
|
else
|
|
{
|
|
@@ -765,10 +765,20 @@
|
|
}
|
|
else
|
|
{
|
|
- /* quantize to 10% step: */
|
|
- quant = (half_res / 10);
|
|
- code = (dpi + quant / 2) / quant;
|
|
- code |= 0x100; /* indicate 10% quantization */
|
|
+ if (s->hw->flags & MUSTEK_FLAG_DOUBLE_RES) {
|
|
+ /* MSF-06000CZ is different... */
|
|
+ quant = half_res / 100;
|
|
+ code = (dpi/2 + quant/2) / quant;
|
|
+ if (code < 1)
|
|
+ code = 1;
|
|
+ /* 0x100 indicates doubled resolution */
|
|
+ } else {
|
|
+ /* quantize to 10% step: */
|
|
+ quant = (half_res / 10);
|
|
+ code = (dpi + quant / 2) / quant;
|
|
+ /* 0x100 indicates 10% quantization */
|
|
+ }
|
|
+ code |= 0x100;
|
|
}
|
|
}
|
|
return code;
|
|
--- mustek.h.orig Sun Oct 11 17:23:26 1998
|
|
+++ mustek.h Sun Oct 11 14:12:52 1998
|
|
@@ -53,6 +53,7 @@
|
|
#define MUSTEK_FLAG_LD_NONE (1 << 7) /* no line-distance corr? */
|
|
#define MUSTEK_FLAG_LINEART_FIX (1 << 8) /* lineart fix/hack */
|
|
#define MUSTEK_FLAG_PP (1 << 9) /* //-port scanner? */
|
|
+#define MUSTEK_FLAG_DOUBLE_RES (1 << 10) /* MSF-06000CZ res. encoding */
|
|
|
|
/* source values: */
|
|
#define MUSTEK_SOURCE_FLATBED 0
|
|
<p>
|
|
---1463811839-1804289383-908120091=:589--
|
|
<p>
|
|
<p>
|
|
<pre>
|
|
--
|
|
Source code, list archive, and docs: <a href="http://www.mostang.com/sane/">http://www.mostang.com/sane/</a>
|
|
To unsubscribe: echo unsubscribe sane-devel | mail <a href="mailto:majordomo@mostang.com">majordomo@mostang.com</a>
|
|
</pre>
|
|
<!-- body="end" -->
|
|
<p>
|
|
<ul>
|
|
<!-- next="start" -->
|
|
<li> <b>Next message:</b> <a href="0151.html">Lowery, Robert: "AcerScan 610S Support"</a>
|
|
<li> <b>Previous message:</b> <a href="0149.html">the developer: "a couple sco sane questions"</a>
|
|
<!-- nextthread="start" -->
|
|
<!-- reply="end" -->
|
|
</ul>
|