<div class="gmail_quote">On Fri, Mar 30, 2012 at 4:57 AM, Ушаков Андрей <span dir="ltr"><<a href="mailto:sorcchan@gmail.com">sorcchan@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_quote">30 марта 2012 г. 2:01 пользователь David Sze <span dir="ltr"><<a href="mailto:sze.david@gmail.com" target="_blank">sze.david@gmail.com</a>></span> написал:<div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_quote"><div><div><div></div><div><br></div></div></div><div>The comments in your source file say:</div><div><br></div><div><br></div><div><div> * Watch original video:</div><div> * vlc video422.raw :demux=rawvid --rawvid-fps=25 --rawvid-width=720 --rawvid-height=576 --rawvid-chroma=UYVY</div>
<div> * Watch "scaled" result:</div><div> * vlc video420p.raw :demux=rawvid --rawvid-fps=25 --rawvid-width=720 --rawvid-height=576 --rawvid-chroma=YV12</div></div><div><br></div><div><br></div><div>So you probably should be using PIX_FMT_UYVY422 instead of PIX_FMT_YUYV422 when doing the conversion.<br>
</div></div></blockquote></div></div><br>Thanks a lot, David! :) Now all works perfectly. I just <span lang="en"><span>thought</span></span> YUYV and UYVY is the same.<br><br>One more question: what PixelFormat is YV12? As I see its not PIX_FMT_YUV420P.<br>
</blockquote><div><br></div><div>They're similar, but the U and V planes are swapped.</div><div><br></div><div><a href="http://wiki.videolan.org/YUV#YUV_4:2:0_.28I420.2FJ420.2FYV12.29">http://wiki.videolan.org/YUV#YUV_4:2:0_.28I420.2FJ420.2FYV12.29</a></div>
<div><a href="http://en.wikipedia.org/wiki/YUV#Y.27UV420p_.28and_Y.27V12_or_YV12.29_to_RGB888_conversion">http://en.wikipedia.org/wiki/YUV#Y.27UV420p_.28and_Y.27V12_or_YV12.29_to_RGB888_conversion</a>
</div><div><a href="http://www.fourcc.org/yuv.php#YV12">http://www.fourcc.org/yuv.php#YV12</a></div><div><a href="http://www.fourcc.org/yuv.php#IYUV">http://www.fourcc.org/yuv.php#IYUV</a></div><div><br></div><div>Note that YUV420P is a.k.a. I420 and IYUV.</div>
<div><br></div><div>The vlc parameter you pass to watch the scaled frame should be I420 instead of YV12.</div><div><br></div></div>