I'm trying to convert images into indexed (3 colour) using a ref image.
Here is the before image:
The output of using my reference image (which is still 24 bit)
And this is what I want (using an image very similar to this as reference image) (ofc I understand it can't be as clean as this)
this is the interesting part of my script - this is taken from an example from I don't remember where - most likely in this forum
Code: Select all
convert input.tif -separate -threshold 75% -combine -remap "..\3_colour_index_ref.tif" indexed\output.tif
2. Is there a way to do what I want?
2.1 I expect that the green/purple colours needs to be mapped to black
2.2 I also expect that the blue range should be remapped to my targeted blue colour.
This is a script that I'll be using for quite many scanned pages, so it'll definately save me a lot of days compared to the manual labour for each page.