[sane-devel] Re: Bug on xsane 0.90 and help

Oliver Rauch oliver.rauch@rauch-domain.de
Wed, 16 Jul 2003 19:37:30 +0200


Hello.

1) The problem with the inherited filedscriptor to the
html viewer is a backend related problem.
My prefered way is that the backend can be opened by
several frontends at the same time and it only does block
when a frontend starts the scan. If the backend can only be
opened by one frontend it may help to add your suggested
fcntl() function, but this must be done in the backend.

2) xsane can reduce the color depth from 48/16 bit to 24/8 bit.
Take a look at preferences->setup->image

Oliver

On Wednesday 16 July 2003 18:56, you wrote:
> Hi, I'm a user of Xsane and I've had some problem with it.
> First, when it starts the browser to view the help, Xsane passes to it =
the
> file descriptor of scanner device file(or better, the browser inherits =
it
> from exec() ). When you open it, you should set the 'close-on-exec' fla=
g
> with fcntl(see its man page).
>
> This created some problem when I closed xsane and left the browser open=
ed:
> - I couldn't "rmmod scanner" to reinsert it with correct parameters lik=
e
> vendor and product ID, the module didn't autodetect my scanner even if
> those ID are present in the sources.
> - I wasn't able to restart xsane because the scanner was open, so busy,
> until I closed the browser. And finding that was not that easy(I used l=
sof,
> a luser wouldn't be able to).
>
> I'm not sure the second part is right, because I had various problems,
> however it is sensible that only one program at a time can open a scann=
er,
> right? I've even given a look to kernel sources that seem to agree with=
 me:
> if (scn->isopen) {
>                 dbg("open_scanner(%d): Scanner device is already open",
> scn_minor);
>                 err =3D -EBUSY;
>                 goto out_error;
>         }
>
>
> Second, on my system, with a HP 3400C USB scanner, the "niash" backend =
is
> used(I didn't find a word in the docs about it). This backend doesn't
> support acquiring data with reduced color depth, so I wasn't able to se=
t
> it. Shouldn't xsane emulate in a general way the reduction of color-dep=
th,
> with the ability to delegate it to the backend if it supports this?

--=20
http://www.xsane.org
http://www.mostang.com/sane
http://www.rauch-domain.de
mailto:Oliver.Rauch@Rauch-Domain.DE