Skip to content

Instantly share code, notes, and snippets.

View pr3sidentspence's full-sized avatar

Pr3sidentSpence pr3sidentspence

View GitHub Profile
@pr3sidentspence
pr3sidentspence / IMprocessBMPscansOnBlackCardstock.bat
Last active October 3, 2019 14:02
A batch file using ImageMagick (https://www.imagemagick.org) to straighten, convert, and trim large bitmap images scanned with a specific (but editable) background color while leaving a some of the background remaining as a border. The fuzz percentage and border left can be given as command line parameters when calling the batch file.
ECHO off
SETLOCAL ENABLEDELAYEDEXPANSION ENABLEEXTENSIONS
REM IMprocessBMPscansOnBlackCarstock.bat
REM Usage: IMprocessBMPscansOnBlackCarstock.bat optional:(fuzz[integer] padding[integer])
REM Creates straightened and cropped with padding 100% quality jpgs
REM of all BMP files in current directory and places them in a subdirectory
REM called output