annotate graphics/colour/luminocity.m @ 61:eff6bddf82e3 tip

Finally implemented perceptual brightness thing.
author samer
date Sun, 11 Oct 2015 10:20:42 +0100
parents 82075c94eed1
children
rev   line source
samer@47 1 function L=luminocity(C)
samer@47 2 % luminocity - Compute perceived brightness of colours
samer@47 3 %
samer@47 4 % luminocity :: [[N,3]] -> [[N]].
samer@47 5
samer@47 6 if size(C,2)~=3 && size(C,1)==3, C=C'; end
samer@47 7 L=C*[.298936021 .58704307445 .114020904255]';