blend function urgently needed in kdelibs

Matthew Woehlke mw_triad at
Tue May 22 00:03:26 BST 2007

David Faure wrote:
> On Tuesday 22 May 2007, Matthew Woehlke wrote:
>> Seven parameters (hehe... actually it's going to be eight) are pretty 
>> well required if it's to be flexible
> Another solution is to create a KColorBlender class, with a number of setter 
> methods and a blend() method (without arguments - i.e. the "do it now" method)...
> OK not sure it makes sense, just thinking out loud about how to avoid 8 params :)

...which is actually how OpenGL works, so the thought /had/ crossed my 
mind :-). And... I might think about it more. I can actually see a 
KColorBlend class with blend(c1, c2, k, r) with k,r optional and reusing 
preset values, but I don't see taking it as far as not even needing the 
input colors. I guess my real question is, does the additional memory 
used justify it?

When in doubt, duct tape!

More information about the kde-core-devel mailing list