Home Products Download Order Contacts


Subject: color modification

It there a way to do the following:

A source color, S
A dest color, D
and a source image

Modify all pixels of the source image so that
1) S is replaced by D
2) all colors Sh (any other color having the same Hue as S) are
replaced by Dh, such that Dh has the same hue as D, and the same
'apparent brightness' of Sh.

I'm not sure what mathematical concept I'm trying to capture with
'apparent brightness', lets call it 'feel'. Maybe that's the key to my
question. If I could pin that down perhaps the algorithm would become

In general terms, I'd like to replace a color in the source image with
another arbitrary color in such a way that all 'closely related colors'
(such as antialiased edges) are replaced as well.

The problem is that the saturation and brightness differences between S
and D may be significant, so a linear mapping of saturation and/or
brightness will not give good values for the Dh colors.



View All Messages in comp.graphics.algorithms


Re: color modification

Copyright 2006 WatermarkFactory.com. All Rights Reserved.