sane-project-website/old-archive/2001-05/0321.html

155 wiersze
6.0 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>sane-devel: Re: [BUG] Epson 1640SU, xsane preview problem</TITLE>
<META NAME="Author" CONTENT="Oliver Rauch (oliver.rauch@rauch-domain.de)">
<META NAME="Subject" CONTENT="Re: [BUG] Epson 1640SU, xsane preview problem">
</HEAD>
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
<H1>Re: [BUG] Epson 1640SU, xsane preview problem</H1>
<!-- received="Thu May 24 02:44:34 2001" -->
<!-- isoreceived="20010524094434" -->
<!-- sent="Thu, 24 May 2001 11:39:52 +0200" -->
<!-- isosent="20010524093952" -->
<!-- name="Oliver Rauch" -->
<!-- email="oliver.rauch@rauch-domain.de" -->
<!-- subject="Re: [BUG] Epson 1640SU, xsane preview problem" -->
<!-- id="3B0CD6E8.2626F0CD@rauch-domain.de" -->
<!-- inreplyto="01052410103500.00606@slowcrap" -->
<STRONG>From:</STRONG> Oliver Rauch (<A HREF="mailto:oliver.rauch@rauch-domain.de?Subject=Re:%20[BUG]%20Epson%201640SU,%20xsane%20preview%20problem&In-Reply-To=&lt;3B0CD6E8.2626F0CD@rauch-domain.de&gt;"><EM>oliver.rauch@rauch-domain.de</EM></A>)<BR>
<STRONG>Date:</STRONG> Thu May 24 2001 - 02:39:52 PDT
<P>
<!-- next="start" -->
<LI><STRONG>Next message:</STRONG> <A HREF="0322.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<UL>
<LI><STRONG>Previous message:</STRONG> <A HREF="0320.html">Henning Meier-Geinitz: "Re: Canon 620S conf file"</A>
<LI><STRONG>In reply to:</STRONG> <A HREF="0319.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<!-- nextthread="start" -->
<LI><STRONG>Next in thread:</STRONG> <A HREF="0322.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<LI><STRONG>Next in thread:</STRONG> <A HREF="0316.html">Oliver Rauch: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<LI><STRONG>Reply:</STRONG> <A HREF="0322.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<!-- reply="end" -->
<LI><STRONG>Messages sorted by:</STRONG>
<A HREF="date.html#321">[ date ]</A>
<A HREF="index.html#321">[ thread ]</A>
<A HREF="subject.html#321">[ subject ]</A>
<A HREF="author.html#321">[ author ]</A>
</UL>
<HR NOSHADE><P>
<!-- body="start" -->
<P>
mh wrote:
<BR>
<P><EM>&gt; Hi Oliver,
</EM><BR>
<EM>&gt; just to let you know, I can reproduce this with the plustek backend too.
</EM><BR>
<EM>&gt; I was browsing through your code this morning, and I think, that the following
</EM><BR>
<EM>&gt; looks suspect:
</EM><BR>
<EM>&gt; In xsane-preview.c (around line 2175/ version 0.76)
</EM><BR>
<EM>&gt; /* See whether there is a saved preview and load it if present: */
</EM><BR>
<EM>&gt; for(level = 2; level &gt;= 0; level--)
</EM><BR>
<EM>&gt; {
</EM><BR>
<EM>&gt; //Problem:
</EM><BR>
<EM>&gt; //If you did a fullsize scan and afterwards e.g. an A5 scan,
</EM><BR>
<EM>&gt; //p-&gt;filename[0] holds a valid filename (== the name of the
</EM><BR>
<EM>&gt; //fullsize preview); therefore the for loop will always count down
</EM><BR>
<EM>&gt; //to 0 and the fullsize preview is reloaded.
</EM><BR>
<EM>&gt; if (p-&gt;filename[level])
</EM><BR>
<EM>&gt; {
</EM><BR>
<EM>&gt; in = fopen(p-&gt;filename[level], &quot;rb&quot;); /* read binary (b for win32) */
</EM><BR>
<EM>&gt; if (in)
</EM><BR>
<EM>&gt; {
</EM><BR>
<EM>&gt; quality = preview_restore_image_from_file(p, in, quality);
</EM><BR>
<EM>&gt; fclose(in);
</EM><BR>
<EM>&gt; }
</EM><BR>
<EM>&gt; }
</EM><BR>
<EM>&gt; }
</EM><BR>
<EM>&gt;
</EM><BR>
<EM>&gt; I don't know, whether this is correct, but may be you can take a look at it.
</EM><BR>
<P>This is correct.
<BR>
level=0 is maximum scanner surface,
<BR>
level=1 is reduced scanner surface, subpart of level 0
<BR>
level=2 is zoomed area, subpart of level 0 and 1
<BR>
<P>quality = preview_restore_image_from_file(p, in, quality);
<BR>
loads the given file when:
<BR>
- it covers the area that has to be shown in the preview window
<BR>
- it has a higher quality than a possibly already loaded image
<BR>
<P>It does not display the complete image, it only uses the wanted subpart.
<BR>
<P>Bye
<BR>
Oliver
<BR>
<P><P><PRE>
--
Homepage: <A HREF="http://www.rauch-domain.de">http://www.rauch-domain.de</A>
sane-umax: <A HREF="http://www.rauch-domain.de/sane-umax">http://www.rauch-domain.de/sane-umax</A>
xsane: <A HREF="http://www.xsane.org">http://www.xsane.org</A>
E-Mail: mailto:<A HREF="mailto:Oliver.Rauch@rauch-domain.de?Subject=Re:%20[BUG]%20Epson%201640SU,%20xsane%20preview%20problem&In-Reply-To=&lt;3B0CD6E8.2626F0CD@rauch-domain.de&gt;">Oliver.Rauch@rauch-domain.de</A>
<P>--
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?Subject=Re:%20[BUG]%20Epson%201640SU,%20xsane%20preview%20problem&In-Reply-To=&lt;3B0CD6E8.2626F0CD@rauch-domain.de&gt;">majordomo@mostang.com</A>
</PRE>
<P><!-- body="end" -->
<HR NOSHADE>
<UL>
<!-- next="start" -->
<LI><STRONG>Next message:</STRONG> <A HREF="0322.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<LI><STRONG>Previous message:</STRONG> <A HREF="0320.html">Henning Meier-Geinitz: "Re: Canon 620S conf file"</A>
<LI><STRONG>In reply to:</STRONG> <A HREF="0319.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<!-- nextthread="start" -->
<LI><STRONG>Next in thread:</STRONG> <A HREF="0322.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<LI><STRONG>Next in thread:</STRONG> <A HREF="0316.html">Oliver Rauch: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<LI><STRONG>Reply:</STRONG> <A HREF="0322.html">mh: "Re: [BUG] Epson 1640SU, xsane preview problem"</A>
<!-- reply="end" -->
<LI><STRONG>Messages sorted by:</STRONG>
<A HREF="date.html#321">[ date ]</A>
<A HREF="index.html#321">[ thread ]</A>
<A HREF="subject.html#321">[ subject ]</A>
<A HREF="author.html#321">[ author ]</A>
</UL>
<!-- trailer="footer" -->
<HR NOSHADE>
<P>
<SMALL>
<EM>
This archive was generated by <A HREF="http://www.hypermail.org/">hypermail 2b29</A>
: <EM>Thu May 24 2001 - 02:45:50 PDT</EM>
</EM>
</SMALL>
</BODY>
</HTML>