[MEncoder-users] How to convert from uncompressed yuv420 video to rgb 24?

gerlos gerlosgm at gmail.com
Mon Feb 23 04:54:43 CET 2009


The Wanderer ha scritto:
> gerlos wrote:
>
>   
>> Hello everyone!
>> I captured  many uncompressed videos (tens of GBs) from my webcam for
>> astronomical processing.
>>
>> The format is YUV420, but my processing software doesn't understand
>> this format, and need rgb24, so I need a way (possibly an automatic
>> way) to convert all these files.
>>
>> Reading the documentation it seems to me that it's possible with
>> mencoder, but so far I couldn't find how... any clue?
>>     
>
> I've never had occasion to do this myself, but from searching the man
> page for 'colorspace', I think that '-vf scale' (and possibly '-vf
> format') might be what you want.
>   

I don't know what's wrong in my previous try with mencoder, it didn't
work, but I found an easy way to convert my video from raw YUV420 to
RGB24 using ffmpeg, and this time is working (maybe because it's easier
to understand for me in this way...).

Here's an example command line:
ffmpeg -i input.avi -vcodec rawvideo -pix_fmt rgb24 output.avi

I wrote a script to convert all my videos and I'm happy with this solution!

regards
gerlos





More information about the MEncoder-users mailing list