(11-06-2022, 08:49 AM)Ofnuts Wrote: But if it is consumed by Inkscape, why do you care about the internal representation? And what is your final target image format?
Many years ago, CorelDraw could import 1-bit black+white images and render each pixel with either of two arbitrary colours (defined as RGBA, HSV, Pantone, or whatever).
The arbitrary colours were not encoded in the imported bitmap. CorelDraw used one attribute (pen) to set the colour of the 'black' pixels, and another (fill) to set the 'white' ones.
On import, CorelDraw rendered black+white as black+transparent by default.
By overlaying and aligning multiple same size bitmaps, it was possible to control the colour and transparency of each pixel in the image. With care, different sized bitmaps could be overlaid, but I forget how I registered them.
I'm trying to accomplish something similar.
(11-06-2022, 11:29 AM)rich2005 Wrote: Not true, just the way IM reports. You can always compare file sizes. This the same image, exported as a 1bit indexed file and then exported as 8bit RGBA.
Edit: If you want IM to report as 1 bit then the same indexed - 1 bit image exported as a tiff.
Thanks rich2005, you've given me some good ideas.
File size is somewhat obscured by compression. Export to BMP is uncompressed by default, but it doesn't do alpha. Can't seem to find any settings to disable compression in other formats. Also, tif export of my source image is buggy in my GIMP.
All that said, I don't think spelunking image formats will solve my problem.
As per above, what I need is to:
- overlay multiple 1-bit bitmaps, with pixel registration.
- map arbitrary rgba values to the '0' and '1' pixels in each overlay. (ie, colour-0 in place of 0 and colour-1 in place of 1).
I've figured it out!
I can do it with layer masks.
I was too focused on bit width, but I just need to copy my 1-bit bitmaps onto the masks.
EXCEPT....
The advantage of using CorelDraw or Inkscape is that they render colours subtractively (like inks), while GIMP's is additive (like prisms).
Maybe something like the layer mode set to Subtract would work. That doesn't do what I want, but there are lots of modes.
Can anyone suggest a way to have red, green and blue add up to black, not white?