[PD] Colour in Digital Video

Mathieu Bouchard matju at artengine.ca
Fri Dec 21 17:57:18 CET 2007

On Sat, 22 Dec 2007, hard off wrote:

> hi andrew.  would love to see some patches that demonstrate what you're 
> talking about, it's all a bit over my head.

Try to zoom into a part of a GEM image that is in the YUV colourspace or 
that formerly was (e.g. digitising a TV signal or taking input from most 
webcams). If the image is as sharp as it can be tuned to be, you will be 
able to see that the colouring of the pixels is blurry compared to their 
intensity. The blur is either horizontal or both horizontal and vertical. 
For example a pure red diagonal bar over pure green background will 
usually show some pixels that are a different shade of red or a different 
shade of green. If it doesn't, it means that you picked two shades that 
have the same brightness, or that the bar is positioned exactly on 
colouring pixel boundaries. The different shades appear because the 
colouring pixels are twice bigger (or more) than the brightness pixels, 
and the boundary of the bar you are filming is being better represented by 
brightness than by colour.

About the non-linearity of vision... This is something else, and a good 
start into that, is to look at gamma correction. Gamma correction is 
actually correcting the monitor, which doesn't output light proportional 
to its electric input, and has to be compensated. I mention gamma because 
the gamma formula is both simple and non-linear, so it's a good starting 
point about non-linearity, but it doesn't actually address the 
non-linearity of vision. You could perhaps look at the HSV colour objects 
that Claude was talking about, and look at how the conversions are made 
(just some floatboxes and one conversion object). It is a common example 
of non-linear mapping from RGB, but it should also be noted that it's not 
linear relative to vision, no matter how superficially it may look like 
it's closer to one's understanding of colours. Look also at when you 
crossfade two colours, even if you tune your gamma correctly, how often 
the average of two colours doesn't feel like it's halfway between the two 

  _ _ __ ___ _____ ________ _____________ _____________________ ...
| Mathieu Bouchard - tél:+1.514.383.3801, Montréal QC Canada

More information about the Pd-list mailing list