udev-device-plug-handler: Scan to PNG

Instead of scanning to the default PNM format, we scan to PNG. PNM isn't
that well-supported in normal image handling software.
This commit is contained in:
MasterofJOKers 2024-05-31 21:23:02 +02:00
parent c2f5732351
commit bbc8180aa2
1 changed files with 2 additions and 1 deletions

View File

@ -134,9 +134,10 @@ class CanonLIDE400(KnownDevice):
'-y', '297mm', '-y', '297mm',
'--mode=Color', '--mode=Color',
'--resolution', '300dpi', '--resolution', '300dpi',
'--format', 'png',
'--button-controlled=yes', '--button-controlled=yes',
# '-p', # progress # '-p', # progress
f"--batch=scan_{now.strftime('%H%M%S')}_%04d.pnm" f"--batch=scan_{now.strftime('%H%M%S')}_%04d.png"
] ]
CanonLIDE400.__process = subprocess.Popen(cmd, stdout=subprocess.DEVNULL, cwd=directory) CanonLIDE400.__process = subprocess.Popen(cmd, stdout=subprocess.DEVNULL, cwd=directory)
print("Handled Canon LiDE 400") print("Handled Canon LiDE 400")