I have the scanner Canon LIDE 210 and recognized that scanning in 600dpi gray results in an image which is wrong. The content in Y-direction is not complete. It looks like first cropped and then stretched to the max y-length of about ~7000 px. Scanning in 600dpi colour works. So I wondered and started a Knoppix 7.4.2 and tried the 600dpi-gray-scan. Result was good. The difference seems to be the version of sane-backends: - 600-dpi-gray-good-Knoppix-7.4.2: the package-dvd.txt shows version 1.0.22 of some libsane packages - 600-dpi-gray-bad-gentoo-actual: media-gfx/sane-backends-1.0.24-r5 is installed To verify it, I installed manually with my portage-overlay media-gfx/sane-backends-1.0.22::Mario from the sources without any patch. (https://alioth.debian.org/frs/download.php/file/3503/sane-backends-1.0.22.tar.gz). 600-dpi-gray-scan works now again. Reproducible: Always Steps to Reproduce: 1. use media-gfx/sane-backends-1.0.24-r5 2. scanimage --format=tiff --resolution 600 > test001.tiff 3. look at the image (no matter if tiff or png) Actual Results: Image looks like first cropped and then stretched. So it is not complete and aspect ratio is wrong. Expected Results: scanned image should look like the original. I will add a screenshot where you see the difference between media-gfx/sane-backends-1.0.22 and media-gfx/sane-backends-1.0.24-r5 (scan_600gray_1.0.22_and_1.0.24.png). # sane-find-scanner -q found USB scanner (vendor=0x04a9 [Canon], product=0x190a [CanoScan]) at libusb:003:006 # scanimage -L device `genesys:libusb:003:006' is a Canon LiDE 210 flatbed scanner
Created attachment 403258 [details] scan_600gray_1.0.22_and_1.0.24 Here you see the difference. Left side: manually installed sane-backends-1.0.22. Right side: actual gentoo sane-backends-1.0.24-r5.
Created attachment 403260 [details] scan_600colour_1.0.24 When using 600dpi and color (instead of gray), it works with sane-backends-1.0.24-r5.
# emerge --info Portage 2.2.19 (python 2.7.9-final-0, default/linux/amd64/13.0, gcc-4.9.2, glibc-2.20-r2, 3.18.11 x86_64) ================================================================= System uname: Linux-3.18.11-x86_64-Intel-R-_Core-TM-_i7-3770_CPU_@_3.40GHz-with-gentoo-2.2 KiB Mem: 16386432 total, 11815124 free KiB Swap: 0 total, 0 free Timestamp of repository gentoo: Thu, 14 May 2015 04:45:01 +0000 sh bash 4.3_p33-r2 ld GNU ld (Gentoo 2.25 p1.0) 2.25 distcc 3.2rc1 x86_64-pc-linux-gnu [disabled] app-shells/bash: 4.3_p33-r2::gentoo dev-java/java-config: 2.2.0::gentoo dev-lang/perl: 5.20.2-r1::gentoo dev-lang/python: 2.7.9-r2::gentoo, 3.3.5-r1::gentoo dev-util/cmake: 3.2.2::gentoo dev-util/pkgconfig: 0.28-r2::gentoo sys-apps/baselayout: 2.2::gentoo sys-apps/openrc: 0.16.1::gentoo sys-apps/sandbox: 2.6-r1::gentoo sys-devel/autoconf: 2.13::gentoo, 2.69-r1::gentoo sys-devel/automake: 1.11.6-r1::gentoo, 1.13.4::gentoo, 1.14.1::gentoo, 1.15::gentoo sys-devel/binutils: 2.25::gentoo sys-devel/gcc: 4.9.2::gentoo sys-devel/gcc-config: 1.8::gentoo sys-devel/libtool: 2.4.6-r1::gentoo sys-devel/make: 4.1-r1::gentoo sys-kernel/linux-headers: 3.18::gentoo (virtual/os-headers) sys-libs/glibc: 2.20-r2::gentoo Repositories: gentoo location: /usr/portage sync-type: rsync sync-uri: rsync://haswell/portage priority: -1000 Mario location: /usr/portage_overlay masters: gentoo priority: 0 ACCEPT_KEYWORDS="amd64 ~amd64 ~x86" ACCEPT_LICENSE="* -@EULA" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-march=core-avx-i -O2 -pipe" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c" CXXFLAGS="-march=core-avx-i -O2 -pipe" DISTDIR="/mnt/base/distfiles" EMERGE_DEFAULT_OPTS="--quiet-build=n" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userpriv usersandbox usersync" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="http://ftp-stud.hs-esslingen.de/pub/Mirrors/gentoo/ http://mirror.netcologne.de/gentoo/ http://mirror.switch.ch/ftp/mirror/gentoo/ http://mirrors.linuxant.fr/distfiles.gentoo.org/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://mirror.switch.ch/ftp/mirror/gentoo/ http://ftp.snt.utwente.nl/pub/os/linux/gentoo http://ftp.spline.inf.fu-berlin.de/mirrors/gentoo/ http://ftp.halifax.rwth-aachen.de/gentoo/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo ftp://de-mirror.org/gentoo/ ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/gentoo/ ftp://mirror.leaseweb.com/gentoo/ ftp://mirror.ovh.net/gentoo-distfiles/ ftp://gentoo.mirror.dkm.cz/pub/gentoo/ ftp://mirror.switch.ch/mirror/gentoo/ ftp://mirrors.linuxant.fr/distfiles.gentoo.org/ ftp://mirror.netcologne.de/gentoo/ ftp://ftp.snt.utwente.nl/pub/os/linux/gentoo ftp://ftp.spline.inf.fu-berlin.de/mirrors/gentoo/ http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/" LANG="de_DE.UTF-8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" MAKEOPTS="-j8" PKGDIR="/mnt/base/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/var/tmp" USE="7zip X a52 aac aacs acl acpi alsa amd64 avx berkdb bluray bzip2 cairo cdparanoia cli cracklib crypt cups custom-cflags custom-cpuopts custom-cxxflags custom-optimization cxx dbus dri dvb dvd dvdr encode exif fam flac fortran g3dvl gdbm gimp glitz gnutls iconv icu ilbc imagemagick imlib ipv6 jpeg kpathsea lame lcms libsamplerate lm_sensors lzo mad mmx mmxext modules mp3 multilib ncurses nls nptl ogg openal opengl openmp openvg pam pcre pdf png qt3support qt4 readline sdl semantic-desktop session smp speex spell sse sse2 sse3 ssl ssse3 svg tcpd theora threads tiff truetype unicode usb v4l vdpau vorbis wmf x264 xcb xcomposite xine xinerama xml xulrunner xv xvid xvmc zlib" ABI_X86="64" ALSA_CARDS="hda-intel" APACHE2_MODULES="alias auth_basic authn_file authz_groupfile authz_host authz_user autoindex deflate dir filter ident log_config logio mime status" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" DVB_CARDS="dibusb-usb1" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="joystick keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="de" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" QEMU_SOFTMMU_TARGETS="x86_64" QEMU_USER_TARGETS="x86_64" RUBY_TARGETS="ruby21" SANE_BACKENDS="genesys" USERLAND="GNU" VIDEO_CARDS="nvidia nv vesa nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" Unset: CPPFLAGS, CTARGET, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Please retry with sane-backends 1.0.25_pre* snapshot
I retried with media-gfx/sane-backends-1.0.25_pre20150628::gentoo USE="ipv6 threads usb" and the problem still exists. 600dpi gray results in an incomplete scan 600dpi color results in a correct scan.
Created attachment 406428 [details] Example The 600dpi gray scan is still incomplete and wrong. Please fix it. There must be a wrong calculation in the source code.
Then, please, report it to upstream as, otherwise, I doubt it will be ever fixed here downstream :( Thanks -> http://www.sane-project.org/bugs.html
Created attachment 408968 [details] sane-backends-1.0.22.ebuild
Created attachment 408970 [details] sane-backends-1.0.23.ebuild
please try the 1.0.22 and 1.0.23 ebuilds and see if either works. that'll help narrow down things (assuming one does).
SpanKY, sane-backends-1.0.22 is the last version without problems. Your ebuilds are not able to fetch the sources. Is there a difference between manually installed version 1.0.22 and your ebuild-version-1.0.22? I am not able to report upstream because I am not able to create an account at sane-project / alioth.debian.org. @sane-project I thought the scanner canon lide 210 were very popular. Why could such a bad bug be introduced in the source code? Is somebody testing the builds after changing source code?
(In reply to Mario Bachmann from comment #11) fetches fine for me, but you didn't post any logs, so i don't know why it's failing for you $ wget https://alioth.debian.org/frs/download.php/file/3752/sane-backends-1.0.23.tar.gz.1 --2015-08-20 05:17:15-- https://alioth.debian.org/frs/download.php/file/3752/sane-backends-1.0.23.tar.gz.1 Resolving alioth.debian.org (alioth.debian.org)... 5.153.231.21 Connecting to alioth.debian.org (alioth.debian.org)|5.153.231.21|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 1792000 (1.7M) [application/binary] Saving to: ‘sane-backends-1.0.23.tar.gz.1’ 100%[=======================================================================================================================================================================================>] 1,792,000 362KB/s in 5.6s 2015-08-20 05:17:22 (315 KB/s) - ‘sane-backends-1.0.23.tar.gz.1’ saved [1792000/1792000]
Created attachment 409722 [details] results_1.0.25_pre20150628.jpeg I downloaded the files for 1.0.23 manually and put it in DISTDIR. I installed your media-gfx/sane-backends-1.0.23 ebuild via my portage-overlay. [ebuild U ] media-gfx/sane-backends-1.0.23::Mario [1.0.22::Mario] USE="ipv6 threads usb ..." ABI_X86="(64) -32 (-x32)" SANE_BACKENDS="genesys ..." 0 KiB /usr/bin/scanimage --version scanimage (sane-backends) 1.0.23; backend version 1.0.23 /usr/bin/scanimage --format=tiff --mode gray --resolution 600 > Test_1.0.23_try2.tiff I scanned with the scanimage command and gimp (via xsane). Results for 1.0.23: [color/600dpi] looks good. [gray/600dpi] looks good. Now I tried again the newest version 1.0.25_pre20150628 [ebuild U ] media-gfx/sane-backends-1.0.25_pre20150628::gentoo [1.0.23::Mario] USE="ipv6 nls%* threads usb ..." ABI_X86="(64) -32 (-x32)" SANE_BACKENDS="genesys" 0 KiB /usr/bin/scanimage --version scanimage (sane-backends) 1.0.25git; backend version 1.0.25 /usr/bin/scanimage --format=tiff --mode color --resolution 600 > Test_1.0.25_pre20150628_color.tiff /usr/bin/scanimage --format=tiff --mode gray --resolution 600 > Test_1.0.25_pre20150628_gray.tiff Results for 1.0.25_pre20150628: [color/600dpi] looks good. [gray/600dpi] is wrong (!). I opened booth pictures and made a screenshot: results_1.0.25_pre20150628.jpeg
Created attachment 409724 [details] different_dpi_1.0.25_pre20150629.jpeg A new test with 1.0.25_pre20150628 in gray mode and different DPI settings (300/600/1200). /usr/bin/scanimage --format=tiff --mode gray --resolution 300 > Test_1.0.25_pre20150628_gray_300.tiff /usr/bin/scanimage --format=tiff --mode gray --resolution 600 > Test_1.0.25_pre20150628_gray_600.tiff /usr/bin/scanimage --format=tiff --mode gray --resolution 1200 > Test_1.0.25_pre20150628_gray_1200.tiff Result is shown in the screenshot of the three images. the middle [gray/600dpi] is wrong (incomplete and stretched vertically.
Created attachment 409726 [details] different_dpi_1.0.25_pre20150629_color.jpeg Same test with COLOR. /usr/bin/scanimage --format=tiff --mode color --resolution 600 > Test_1.0.25_pre20150628_color_600.tiff Finally the 1.0.25_pre20150628 in color mode and different DPI settings (300/600/1200). All images look correct and complete.
thanks, that helps narrow down the issue between 1.0.23 and 1.0.24, which is still like 373 commits in upstream. there are a few suspicious ones for that driver that might be worth checking out. i've added a 9999 ebuild to the tree that you can use to try and bisect. set EGIT_COMMIT before emerging it to try older versions. something like: $ EGIT_COMMIT='RELEASE_1_0_24~150' emerge ~sane-backends-9999 you'll want to use diff values to narrow down the bad commit: EGIT_COMMIT='RELEASE_1_0_24' EGIT_COMMIT='RELEASE_1_0_24~100' EGIT_COMMIT='RELEASE_1_0_24~200' EGIT_COMMIT='RELEASE_1_0_24~300' don't go above 400 though as that goes past the 1.0.23 version. you should be able to manually bisect down the numbers i think.
Where do I find sane-backends-9999? Do I need to add an overlay? I did an "emerge --sync" and I only see sane-backends-1.0.24-r5.ebuild sane-backends-1.0.25_pre20150628.ebuild in the folder /usr/portage/media-gfx/sane-backends/
(In reply to Mario Bachmann from comment #17) i just committed it, and rsync mirrors don't update instantly, so you'll have to wait a bit
After a lot compiling I found the introduction of the bug. Last version which works perfect: EGIT_COMMIT='RELEASE_1_0_24~55' emerge -v ~sane-backends-9999 Image [gray/600dpi] is correct. First version with the problem: EGIT_COMMIT='RELEASE_1_0_24~54' emerge -v ~sane-backends-9999 Image [gray/600dpi] is incomplete (cropped and stretched).
i've filed a bug upstream now, but really you'll need to follow up if they have questions. i'm not going to play telephone here.