RSS/Atom feed Twitter
Site is read-only, email is disabled

generate png images with transparent pixel that filled with correct color on viewers do not support transparency

This discussion is connected to the gimp-user-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

???
2006-12-14 02:56:17 UTC (over 17 years ago)

generate png images with transparent pixel that filled with correct color on viewers do not support transparency

The email subject says it all, though it's very long.

I am used to creating png images with transparent pixels/area that I can safely (safe = even work with the worst browser that people call IE) use on the web, the trick is to convert image with transparency to indexed color with less then 256 colors, save the png image.

Now another challenge: I use very bright background color on the web for most png-pixel-transparent images, these images look very bad if they are put on dark background. And for one situation I am in now I have to make these images display fine on viewers that do not support transparency, e.g. xview.

My png image (with transparent pixels) display on xview with very dark background color, close to black. First I thought it's because white color is not in the color index, and I open gimp to add white color in the index map (verified by adding a single white pixel stored and displayed), and save as png image (when saving, gimp's background color setting is also set to white), and I get a new png image that display very dark red color on xview.

I think perhaps it's possible to set what transparent pixel color value in GIMP? How should I set this value?

Thanks a lot in advance

Saul Goode
2006-12-14 04:17:23 UTC (over 17 years ago)

generate png images with transparent pixel that filled with correct color on viewers do not support transparency

I think perhaps it's possible to set what transparent pixel color value in GIMP? How should I set this value?

You should be able to perform an "Alpha to Selection", "Selection Invert", "Edit-Fill" with the appropriate color, and then "Edit->Clear". You might need to do a colors->threshold on the QuickMask (of the selection) if you only wish to change the color of *fully* transparent pixels.

--------
"It is amazing what you can accomplish if you do not care who gets the credit." -- Harry S. Truman

David Gowers
2006-12-14 04:52:07 UTC (over 17 years ago)

generate png images with transparent pixel that filled with correct color on viewers do not support transparency

On 12/14/06, ?

Jozef Legeny
2006-12-14 11:55:07 UTC (over 17 years ago)

generate png images with transparent pixel that filled with correct color on viewers do not support transparency

On 12/14/06, David Gowers wrote:

On 12/14/06, ?? wrote:

The email subject says it all, though it's very long.

I am used to creating png images with transparent pixels/area that I can safely (safe = even work with the worst browser that people call IE) use on the web, the trick is to convert image with transparency to indexed color with less then 256 colors, save the png image.

Now another challenge: I use very bright background color on the web for most png-pixel-transparent images, these images look very bad if they are put on dark background. And for one situation I am in now I have to make these images display fine on viewers that do not support transparency, e.g. xview.

If I select the transparent area, clear it to the color I want, then clear it to transparency, and save with 'save background color' ON and 'save color values from transparent pixels' OFF, then xview uses that color correctly.

_______________________________________________ Gimp-user mailing list
Gimp-user@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user

the trick is to have the image saved always with full alpha and transparency (AND in xcf format). Then all you have to do is to have one layer with foreground (for example an icon or a button) and another layer under it filled with background color. Make sure that your foreground is well adapted to any background color. Then when you want to save your final image you save it in another file and perform the indexing operation and give it a transparent color.