I used an old Microsoft app, Image Composer, for various web graphics. (IC was included on the installation CD for Front Page at one time, but is now no longer supported.) I used the same background color that I am using as a background for the web page, to create the impression of a transparent graphic. However, I am finding that the color generated by IC (after exporting it as a JPEG) does not match the same color as generated by any other app, including IE, MS Paint and an Adobe image editor. I specify the color using RGB numbers.
Am I doing something wrong, or am I just stuck with an eccentric application?
To work around this, I created a 1-pixel graphic with IC using the background color, and then specified that graphic as the background image in HTML.
You can’t count on getting a precise, specified colour from a jpeg because of the nature of jpeg compression, which involves apporiximation. Also, jpeg isn’t very good for large areas of uniform colour. Try using PNG or GIF or some other format. They support true transparency as well.
I’ve never found PNG to live up to any of its promises. They claim it’s better compression than a GIF or JPEG and better image quality. This is nonsesne, in my experience.
So go for GIF, though that may depend on number of gradient colours (photographic) or pic dimensions to get an efficient download size.
Well, even if you are not a big fan of png, the Original poster still must understand that if color matching is required, a format other than jpeg must be used.
Think of it this way… jpeg supports 24bit color - millions of color, if you will. You just don’t get to choose which colors.
gif only allows 256 colors, but you can have pricise control over all of them.
Additionally, you can edit and resave a gif file. Editing and resaving a jpeg results in the file being recompressed, degrading the image.
Still, when color matching isn’t critical, and reediting will not be required, jpeg is generally great for photographs.
PNG compression is only ‘better’ insofar as it is lossless, and not encumbered by patents as GIF compression is (and yes, this is a big deal to some people). You won’t get smaller filesizes than JPEG with PNG, but it will reproduce colors correctly.
There was a time, a few years ago, when PNG was touted as the way all images should be. I’m not sure why, though, apart from, as you say, better image quality. Which, obviously, not a lot of people cared too much about because they have barely made any impact at all.
On a tenuously related note, does anyone know how Flash animations are so much faster, smoother, higher quality, and smaller filesizes than ever before?
I learned to use it when it first came out, not very well I may say, and haven’t really touched it since. The latest ads, anims, and games it does now are amazing improvements. I’m impressed.