[sane-devel] XSANE: memory limits?
Oliver Rauch
Oliver.Rauch at Rauch-Domain.DE
Thu Dec 8 20:09:33 UTC 2005
Hello Doug,
xsane (the frontend) allocates its memory dynamically.
In general the image is not stored as complete image in memory. The
image is saved directly to a file. Only the viewer loads the image into
the memory.
Converting the file format to e.g. tiff, jpg, ... only allocates the
memory that is necessary to store one line. (I am not sure what libjpeg,
libtiff etc do internally, but I expect that these libraries do not
allocate the memory for the complete image).
When you are not able to scan images larger than 160MB then I expect
that this limitation
a) comes from the backend
or
b) your system is not able to allocate a memory block in the requested
size.
When you explain what you do and give the exact error message and
condition then we could be able to tell a bit more about it.
Does the error depend on the selected image saving format?
You can enable the debug output of the backend by setting the
environment variable SANE_DEBUG_"backendname" e.g. to 128 (where you
have to replace "backendname" by the name of the backend that supports
your scanner.
The xsane debug messages are enabled by setting the environment variable
XSANE_DEBUG e.g. to 12
best regards
Oliver
Am Don, 2005-12-08 um 20.03 schrieb Doug Jones:
> I hooked up an Epson Perfection 2400 Photo scanner to my Ubuntu system
> recently.
>
> Just for the heck of it, I tried to scan a really big image, at maximum
> resolution, and 48-bit color. Not surprisingly, XSane gave me an error
> message. I wasn't really expecting it to actually give me a 6 GB image
> file (I only have 2 GB of RAM on this machine).
>
> I did some experiments, and discovered that I couldn't get an
> (uncompressed) image file larger than about 160 MB from XSane using this
> scanner.
>
> I don't have an immediate need for images larger than this, but I can
> imagine wanting to someday, and anyway I abhor arbitrary limits.
>
> My question is: Where does this arbitrary limit come from? Is it in
> the Sane driver for this particular scanner, or is it built-in to XSane?
>
> These experiments were done on an AMD64 machine with 2 GB of RAM, using
> Ubuntu 5.10 and the version of XSane it ships with (0.97). Both the
> AMD64 port and the x86 port of Ubuntu were tried, with the same results.
>
>
> Thanks...
>
More information about the sane-devel
mailing list