<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<META content="MSHTML 6.00.6000.16414" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>Hello
all,</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>I'd
like to convert the theora yuv_buffer to RGB that I can render onto a
texture.</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2>Googling around, there are a tone of different formulae to do
so.</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>There
is this (with lots of corrections and amendments further down the
page):</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2><A
href="http://www.fourcc.org/fccyvrgb.php">http://www.fourcc.org/fccyvrgb.php</A></FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>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,</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>and
then it has it's own set of formulae here:</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2><A
href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceddraw/html/_dxce_converting_between_yuv_and_rgb.asp">http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceddraw/html/_dxce_converting_between_yuv_and_rgb.asp</A></FONT></SPAN></DIV>
<DIV><FONT face=Arial color=#800000 size=2></FONT> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>I was
wondering if anyone has a definitive answer on this ;-)</FONT></SPAN></DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000 size=2>Also,
performance wise, is it better to do the conversion to RGB in a shader, or is it
better to use GL_LUMINANCE8 textures?</FONT></SPAN></DIV>
<DIV><FONT face=Arial color=#800000 size=2></FONT> </DIV>
<DIV><SPAN class=009291310-03052007><FONT face=Arial color=#800000
size=2>cheers,</FONT></SPAN></DIV>
<DIV align=left><FONT face=Verdana
size=1>_________________________________________________<BR><B>kostas kostiadis
| lead programmer | <FONT color=#ff0000>climax action</FONT><BR></B><FONT
color=#666666>work: </FONT><A href="mailto:kos@climaxgroup.com"><FONT
color=#666666>kos@climaxgroup.com</FONT></A><FONT color=#666666> | </FONT><A
href="http://www.climaxgroup.com/"><FONT
color=#666666>www.climaxgroup.com</FONT></A><FONT color=#666666><BR></FONT><FONT
color=#999999>home: </FONT><A href="mailto:kos@kostiadis.com"><FONT
color=#999999>kos@kostiadis.com</FONT></A><FONT color=#999999> | </FONT><A
href="http://www.kostiadis.com/"><FONT
color=#999999>www.kostiadis.com</FONT></A></FONT></DIV>
<DIV><FONT face=Arial size=1></FONT> </DIV>
<DIV> </DIV></BODY></HTML>