select scan resolution more conservatively

Bug #545807 reported by Alesh Slovak on 2010-03-24
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Simple Scan
Fix Released
simple-scan (Ubuntu)

Bug Description

I work on the epkowa SANE backend that supports Epson scanners.

I tested simple-scan 0.9.7 on Ubuntu 10.04 beta 1. It appears that simple-scan chooses a non-optimal resolution setting when confronted with a scanner that does not directly support the resolutions that are in its menus.

For example, with the Epson GT-X820/Perfection V600 Photo scanner the epkowa backend reports the following supported resolutions (ignoring the more complex X and Y resolutions):
400, 800, 1600 and 3200 dpi

Note that none of these resolutions are found in simple-scan's menus.
When I tried scanning with the default resolution of 300 dpi, simple-scan actually selected 3200 dpi at which point the scan failed because the scanner cannot actually scan the full area at such a high resolution. Using another scanner, that supports a resolution of 300 dpi directly, resulted in a successful scan.

Ignoring the scan failure itself, which is an ancillary issue, I would suggest a more conservative resolution selection strategy. For example, in the above case, it might be a better idea to select the closest resolution of 400 dpi instead of going straight for the maximum resolution of 3200 dpi.

Other SANE frontends, including scanimage, handle this case as I would expect by selecting 400 dpi.

A cursory look at the simple-scan source left me non-the-wiser as to where this logic was going on. I guess set_int_option and set_double_option in src/scanner.c should be doing this job?

I've attached a log of the failed scan attempt at 300 dpi with the Epson Perfection V600

Robert Ancell (robert-ancell) wrote :

Thanks Alesh, fixed broken logic in src/scanner.c:set_int_option

Changed in simple-scan:
status: New → Fix Committed
importance: Undecided → Medium
Changed in simple-scan (Ubuntu):
status: New → Fix Committed
importance: Undecided → Medium
Changed in simple-scan:
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package simple-scan - 0.9.10-0ubuntu1

simple-scan (0.9.10-0ubuntu1) lucid; urgency=low

  * New upstream release:
    - Change default scan direction to top-to-bottom
    - Call sane_cancel after each document, not duing multi page scans
      (LP: #536864)
    - Set X-GNOME-Gettext-Domain in .desktop file (LP: #538977)
    - Fix memory leak in page_set_scan_area()
    - Fix read buffering when reading large images
    - Fix moving crop on pages after first (LP: #542830)
    - Load color profiles for scanner and save them in output files
    - Fix broken logic in picking nearest supported scan resolution
      (LP: #545807)
    - Add save button back into toolbar (LP: #543384)
    - Put text beside crop toolbutton (LP: #543384)
    - Merge document type into scan menu (LP: #543384)
  * debian/control:
    - Build-depend on libdput-glib-1-dev
 -- Robert Ancell <email address hidden> Thu, 25 Mar 2010 12:42:38 +1100

Changed in simple-scan (Ubuntu):
status: Fix Committed → Fix Released
Alesh Slovak (alesh-slovak) wrote :

Using Ubuntu 10.04 Beta 1 and the Epson Perfection V600, I downloaded the latest simple-scan 0.9.10-0ubuntu4 package and confirmed that scanning with the default resolution of 300 dpi requests the expected 400 dpi from the driver and the scan completes successfully.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers