sane-project-website/old-archive/1999-08/0152.html

69 wiersze
3.4 KiB
HTML
Czysty Wina Historia

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

<!-- received="Sat Aug 14 17:20:48 1999 PDT" -->
<!-- sent="Sun, 15 Aug 1999 01:20:05 +0100 (GMT)" -->
<!-- name="Nick Lamb" -->
<!-- email="njl98r@ecs.soton.ac.uk" -->
<!-- subject="Re: Starting a discussion about SANE and TWAIN..." -->
<!-- id="" -->
<!-- inreplyto="199908142225.PAA01622@icarus.com" -->
<title>sane-devel: Re: Starting a discussion about SANE and TWAIN...</title>
<h1>Re: Starting a discussion about SANE and TWAIN...</h1>
<b>Nick Lamb</b> (<a href="mailto:njl98r@ecs.soton.ac.uk"><i>njl98r@ecs.soton.ac.uk</i></a>)<br>
<i>Sun, 15 Aug 1999 01:20:05 +0100 (GMT)</i>
<p>
<ul>
<li> <b>Messages sorted by:</b> <a href="date.html#152">[ date ]</a><a href="index.html#152">[ thread ]</a><a href="subject.html#152">[ subject ]</a><a href="author.html#152">[ author ]</a>
<!-- next="start" -->
<li> <b>Next message:</b> <a href="0153.html">Andreas Beck: "Re: Starting a discussion about SANE and TWAIN..."</a>
<li> <b>Previous message:</b> <a href="0151.html">becka@rz.uni-duesseldorf.de: "SANE V2 - past discussions. A summary."</a>
<li> <b>In reply to:</b> <a href="0150.html">Stephen Williams: "Re: Starting a discussion about SANE and TWAIN..."</a>
<!-- nextthread="start" -->
<li> <b>Next in thread:</b> <a href="0153.html">Andreas Beck: "Re: Starting a discussion about SANE and TWAIN..."</a>
<!-- reply="end" -->
</ul>
<!-- body="start" -->
On Sat, 14 Aug 1999, Stephen Williams wrote:<br>
<p>
<i>&gt; However, I want to be able to write SANE front-ends that can drive my</i><br>
<i>&gt; back-end at those sorts of rates. I have put considerable effort into</i><br>
<i>&gt; making sure the kernel mode device driver does *not* copy lots of image</i><br>
<i>&gt; buffers around (app mmaps the image buffer which the card can access</i><br>
<i>&gt; via DMA) and I don't want to see a SANE standard that does gratuitous</i><br>
<i>&gt; copies.</i><br>
<p>
Image data goes through sane_read, which is defined as:<br>
<p>
sane_read (SANE_Handle h, SANE_Byte * buf, SANE_Int maxlen, SANE_Int * len);<br>
<p>
This means that the backend is required to copy at most maxlen bytes<br>
into the buffer (buf) which was provided by the frontend. This interface<br>
is not optional, and should incur exactly one copy, which I don't think<br>
is unreasonable.<br>
<p>
In a typical localhost scenario the backend is a dynamically loaded<br>
shared object, added to the frontend at runtime, and sharing the same<br>
process space. Most such backends seem to fork() in order to do the<br>
heavy lifting in a separate process, but that's entirely optional.<br>
<p>
Does this sound alright, or is Zero Copy absolutely a must for your<br>
proposed application?<br>
<p>
Nick.<br>
<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="0153.html">Andreas Beck: "Re: Starting a discussion about SANE and TWAIN..."</a>
<li> <b>Previous message:</b> <a href="0151.html">becka@rz.uni-duesseldorf.de: "SANE V2 - past discussions. A summary."</a>
<li> <b>In reply to:</b> <a href="0150.html">Stephen Williams: "Re: Starting a discussion about SANE and TWAIN..."</a>
<!-- nextthread="start" -->
<li> <b>Next in thread:</b> <a href="0153.html">Andreas Beck: "Re: Starting a discussion about SANE and TWAIN..."</a>
<!-- reply="end" -->
</ul>