[theora] converting YUV to RGB

Kostas Kostiadis kos at climaxgroup.com
Thu May 3 03:25:57 PDT 2007


Hello all,
 
I'd like to convert the theora yuv_buffer to RGB that I can render onto a
texture.
Googling around, there are a tone of different formulae to do so.
There is this (with lots of corrections and amendments further down the
page):
 
http://www.fourcc.org/fccyvrgb.php <http://www.fourcc.org/fccyvrgb.php> 
 
and there is the MSDN stuff that says you need to convert 4:2:0 and 4:2:2 to
4:4:4 first, before you do anything,
and then it has it's own set of formulae here:
 
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceddraw/ht
ml/_dxce_converting_between_yuv_and_rgb.asp
<http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceddraw/h
tml/_dxce_converting_between_yuv_and_rgb.asp> 
 
 
I was wondering if anyone has a definitive answer on this ;-)
 
Also, performance wise, is it better to do the conversion to RGB in a
shader, or is it better to use GL_LUMINANCE8 textures?
 
cheers,
_________________________________________________
kostas kostiadis | lead programmer | climax action
work:  <mailto:kos at climaxgroup.com> kos at climaxgroup.com |
<http://www.climaxgroup.com/> www.climaxgroup.com
home:  <mailto:kos at kostiadis.com> kos at kostiadis.com |
<http://www.kostiadis.com/> www.kostiadis.com
 
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xiph.org/pipermail/theora/attachments/20070503/0d8debbd/attachment.html


More information about the theora mailing list