Take the 2-minute tour ×
Video Production Stack Exchange is a question and answer site for engineers, producers, editors, and enthusiasts spanning the fields of video, and media creation. It's 100% free, no registration required.

I'm trying to create a screencast for playback on the web. Would like to use h.264, webm, and ogg. The source files are in the Apple Animation codec, and they look perfectly accurate. However when I try to convert to mp4 using ffmpeg lossless settings, there is some definite degradation. It seems to be because the source is RGB and ffmpeg auto-selects yuv420p instead.

Incompatible pixel format 'rgb24' for codec 'libx264', auto-selecting format 'yuv420p'

Anyone know how to get the same color accuracy with mp4/h.264 as with Apple Animation?

Thanks

share|improve this question
add comment

3 Answers

H.264 does support true lossless compression (see 'Lossless mode' on this page). It seems that to avoid chroma format conversion, you need to encode using the Hi444PP profile, which accepts RGB pixels. However, a cursory search indicates that x264 doesn't support Hi444PP (yet), whereas some commercial codecs like MainConcept do.

share|improve this answer
    
Seems like maybe a high bitrate would be a good alternative. Of course the OP has long since dealt with this problem one way or another by now. –  Matt Browne Feb 25 '13 at 21:28
add comment

If you need something less complicated try rec, which is mine :) https://sites.google.com/site/joopeter/

It is also free, lossless but more efficient and accurate!

share|improve this answer
add comment

if you want yuv444p try something like this: "-vcodec libx264 -pix_fmt yuv444p"

https://trac.ffmpeg.org/wiki/x264EncodingGuide#LosslessH.264 seems to imply that lossless (or practically lossless) is available via -qp 0

share|improve this answer
    
You can also use -crf 0 with 8-bit builds of x264. The only reason -qp is used instead is because 10-bit builds of x264 uses different values for -crf (I believe -crf -12 for 10-bit would be lossless) to achieve a similar visual quality. –  LordNeckbeard Jan 16 at 18:42
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.