bwcrop — crop black and white bw files
bwcrop
in.bw
out.bw
bwcrop
in.bw
out.bw
inwidth
outwidth
outheight
ulx
uly
urx
ury
lrx
lry
llx
lly
Bwcrop crops any quadrilateral out of an arbitrarily large bw(5) input file (in.bw), squares that region to a given height and width output size, and writes the result to out.bw. The first form of bwcrop prompts for all parameters it needs to do the cropping. All responses should be pixel counts or first quadrant coordinates. The second form allows all of the needed parameters to be given on the command line and is intended for use from shell scripts. The coordinate names stand for upper-left-x, lower-right-y, etc.
The nearest input pixel is selected for each output pixel. No interpolation is done by this program.