[sane-devel] Problems with AutoStep.

Oliver Rauch oliver.rauch@rauch-domain.de
Mon, 08 Apr 2002 21:54:57 +0200


Hello.

I can reproduce this. changing
int counter;
to
long long int counter;

and replacing the %d by %Ld

would solve this problem, but it is not ansi C and will not
be portable to all systems.
I also do not like to use a float or double value here.

I think the best is to reduce the counter length to 9 digits
and to make sure that the value is untouched when counter len is
set to inactive.

Any comments?

Bye
Oliver

Michael Chapman wrote:
> 
> Don't know if this is a bug, or just abuse by the user.
> 
> I was scanning in a series of images and giving each one a filename 'by hand'.
> The filenames were purely numeric, and all ten digits. (Yep, I was scanning
> bookcovers and filing them by ISBNs!)
> 
> Problem 1:
>         File names beginning with 0 are truncated to nine digits.
>         Setting STEP to "0" does not cure this.
> 
> Problem 2:
>         I started out leaving STEP at 1 (I was afterall re-entering a new file name
> for each scan, so was not worried about what xSane thought the next one
> should be.)
>         I then had an underrun error message for the step counter.
>         That did not worry me, but subsequently everytime I entered a new file name
> xSane erased it and replaced it by 2147483647.png (that is [2^31 - 1].png, I
> think).
>         Setting STEP to 0 would not deter it.
>         (Rather than restrating xSane, I changed file naming strategy to
> 1234567890isbn.png.)
> 
> Both (that is truncating a filename and not being able to break out of an
> increment error even when increment is switched off) strike me as 'errors',
> albeit errors of (a) a relatively minor nature and (b) in 'exotic'
> circumstances.
> 
> Regards,
> 
>         Michael Chapman
> 
> PS Having used autoincrement for scanning several hundred other images in one
> series (and not having had it on my old non-Sane scanner) I do appreciate its
> definite merits!  MC
> _______________________________________________
> Sane-devel mailing list
> Sane-devel@www.mostang.com
> http://www.mostang.com/mailman/listinfo/sane-devel

-- 
Homepage:	http://www.rauch-domain.de
sane-umax:	http://www.rauch-domain.de/sane-umax
xsane:		http://www.xsane.org
E-Mail:		mailto:Oliver.Rauch@rauch-domain.de