FAX conversion results in reversing black on white images

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
terrapinsail

FAX conversion results in reversing black on white images

Post by terrapinsail »

I have a Group4 TIFF that I need to convert to a Group3 FAX. The command convert -compress fax tifg4.tif tifg3.tif , results in an image where the background is black and the text is white. Any idea why this is happening and/or a modification to the command line above to correctly convert the image without changing the black and white pages? thanks.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: FAX conversion results in reversing black on white images

Post by fmw42 »

I don't know much about Tiff faxes, but a workaround might be

convert -compress fax tifg4.tif -negate tifg3.tif

or

convert tifg4.tif -compress fax -negate tifg3.tif
terrapinsail

Re: FAX conversion results in reversing black on white images

Post by terrapinsail »

Thanks that sorta worked. The document is a multipage tif with one color page. Using the command 'convert -compress fax tif1.tif tif2.tif results in all b/w pages turning to white on black and the color page looking like the source page (just fine). Taking your recommendation and running 'convert -compress fax tif1.tif -negate tif2.tif, retains the black on white for the b/w pages, but it reverses the color on the color page! help :)
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: FAX conversion results in reversing black on white images

Post by fmw42 »

separate the pages/frames, process only the b/w white with -negate, then recombine.

convert image.tif image_%d.tif

will separate them.

Then process the non-color ones

convert image_01.tif -negate image_01.tif
convert image_02.tif -negate image_02.tif
etc

Then recombine all the frames

convert image_01.tif .... image_0n.tif image_new.tif
Post Reply