1 |
On Mon, 1 Mar 2021 11:50:35 +0000, Wols Lists wrote: |
2 |
|
3 |
> I've got a bunch of scans, let's assume they're text documents. And |
4 |
> they're rather big ... I want to email them. |
5 |
> |
6 |
> How on earth do I convert them to TRUE b&w documents? At the moment they |
7 |
> are jpegs that weigh in at 3MB, and I guess they're using about 5 bytes |
8 |
> to store all the colour, luminance, whatever, per pixel. But actually, |
9 |
> there's only ONE BIT of information there - whether that pixel is black |
10 |
> or white. |
11 |
> |
12 |
> I'm using imagemagick, but so far all my attempts to strip out the |
13 |
> surplus information have resulted in INcreasing the file size ??? |
14 |
> |
15 |
> So basically, how do I save an image as "one bit per pixel" like you'd |
16 |
> think you'd send to a B&W printer? |
17 |
|
18 |
$ convert input.jpg -threshold 50% output.png |
19 |
|
20 |
should do it, you may need to play with the threshold setting. The file |
21 |
command reports the output file as being "1-bit grayscale". |
22 |
|
23 |
You can also use -monochrome but that will produce a dithered image, |
24 |
that's probably not what you want judging by your description. |
25 |
|
26 |
|
27 |
-- |
28 |
Neil Bothwick |
29 |
|
30 |
If we aren't supposed to eat animals, why are they made of meat? |