I am saving a black and white (with transparency) image, after color
map, as GIF and PNG. The PNG image retains the original sharpness and
GIF shows some distortions.
Following are the image samples:
B&W image: http://www.stutimandal.com/images/contact_bw.png
PNG image after color map:
http://www.stutimandal.com/images/contact_cldblue.png
GIF image after color map:
http://www.stutimandal.com/images/contact_cldblue.gif
Am I doing something wrong? As far as I understand, GIF is lossless and
should not show any distortion? Do I have to upgrade GIMP or change some
settings?
Best regards,
Animesh
> PNG image after color map:
> http://www.stutimandal.com/images/contact_cldblue.png
>
> GIF image after color map:
> http://www.stutimandal.com/images/contact_cldblue.gif
>
> Am I doing something wrong? As far as I understand, GIF is lossless and
> should not show any distortion? Do I have to upgrade GIMP or change some
> settings?
GIF is lossless if you have a 256 color image with no transparency or a
255 color image with 1-bit transparency, i.e. every pixel is either
complete opaque and has one of the 255 colors or it is complete
transparent. PNG on the other hand has 8-bit transparency even in indexed
mode.
Ciao,
Marc 'BlackJack' Rintsch
Thanks for the answer. I understand GIF better now.
>Thanks for the answer. I understand GIF better now.
Note that PNG supports several different modes. These are:
- paletted images of 2, 4, 16 or 256 colors, where one color may be
marked as transparent (just like GIF)
- gray-scale images with 8 or 16 bit color depth
- true-color images with 24 or 48 bit color depth
- The latter two may also have a true alpha channel of 8 or 16 bpp.
In case you didn't know: If you open a paletted image, GIMP will not
automatically convert it to RGB-color, but rather tries to work with the
available colors. This will cause many operations to either produce odd
results or simple be not available at all.
2 things.
1. Does that mean you should switch the mode to RGB manually for all
palleted images?
2. How do you know if an image is palleted (sorry, this is probably
just my ignorance)?
--
-Lost
Remove the extra words to reply by e-mail. Don't e-mail me. I am
kidding. No I am not.
>1. Does that mean you should switch the mode to RGB manually for all
>palleted images?
Depends on what operations you intend to perform on the image. Converting RGB
back to palette is a lossy process, so you should avoid doing it more often
than necessary.
Just remember that any operation on a palette image will have to work with
the limited amount of colors that are already defined there.
E.g. if all palette entries are red and green tones, then you cannot even
insert a blue text.
So, for many cases you don't have a choice other than to convert to RGB.
>2. How do you know if an image is palleted (sorry, this is probably just
>my ignorance)?
View > Info window
or just look which item under Image > Mode is grayed out.
Thank you very much.