[sane-devel] OT: scanimage output format
m. allan noah
anoah at pfeiffer.edu
Mon Oct 27 16:58:08 GMT 2003
not possible to use png's progressive loading, cause it uses Adam7, which
needs a low-resolution version of the image at the beginning of the file,
followed by multiple (effectively) higher res versions.
if your client is timing out, you could try sending them a redirect to
keep the page refreshed. but then you will need to store your output on
the fs or in a db for retrieval...
allan
On Mon, 27 Oct 2003, Wolfgang Pichler wrote:
> hi all,
>
> for a webapplication i am calling scanimage the scan a contract in the
> client scanner - i am calling it with
> $fd = popen('SANE_DEFAULT_DEVICE="net:'.$client_ip.':plustek" scanimage
> -l 0 -t 0 -x 210 -y 288 --mode Gray | pnmtopng','r');
> $output = "";
> while(!feof($fd)) {
> $output .= fread($fd, 1024);
> }
> pclose ($fd);
> echo $output;
>
> (the correct headers also get set before)
>
> this already works.
>
> But with that call the hole image gets scanned and that converted into
> png format (so that the browser can read it). What I'd like is to get
> scanimage to output the scan directly in png format (or a program which
> can directly process the the data and convert it to png on the fly -
> while the scan still runs) - so that while the scan runs the scan get
> directly outputed on the client (so that the user can see the progress).
> Is this possible ? And if its possible, how ?
>
> mfG
> Wolfi
>
>
>
> _______________________________________________
> sane-devel mailing list
> sane-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/mailman/listinfo/sane-devel
>
--
"so don't tell us it can't be done, putting down what you don't know.
money isn't our god, integrity will free our souls" - Max Cavalera
More information about the sane-devel
mailing list