[FFmpeg-user] LLossless (10 Bit RGB 444) and (10 Bit YUV 422) Compression

Jason Freets jasonslife at hotmail.com
Wed Dec 31 01:24:19 CET 2014

> To: ffmpeg-user at ffmpeg.org
> From: cehoyos at ag.or.at
> Date: Tue, 30 Dec 2014 23:52:40 +0000
> Subject: Re: [FFmpeg-user] LLossless (10 Bit RGB 444) and (10 Bit YUV 422)	Compression
> Jason Freets <jasonslife <at> hotmail.com> writes:
> > ffmpeg -f lavfi -i testsrc -t 10 -vcodec r10k out.avi
> > 
> > Yes, this does work. It creates a R10K (Big Edian) 
> > video file. The R10K (Big Edian) video file does play.
> With FFplay? Or did you test another application?

// Testing Under Linux
// Running: 
// ffmpeg -f lavfi -i testsrc -t 10 -vcodec r10k out.avi

Input #0, lavfi, from 'testsrc':
  Duration: N/A, start: 0.000000, bitrate: N/A
    Stream #0:0: Video: rawvideo (RGB[24] / 0x18424752), rgb24, 320x240 [SAR 1:1 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
[swscaler @ 0x3644020] full chroma interpolation for destination format 'rgb48le' not yet implemented
Output #0, avi, to 'out.avi':
    ISFT            : Lavf56.16.102
    Stream #0:0: Video: r10k (R10k / 0x6B303152), rgb48le, 320x240 [SAR 1:1 DAR 4:3], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc
      encoder         : Lavc56.19.100 r10k

The result of the above, outputs an out.avi that is R10k (Big Endian) in Linux.

Copying the out.avi file in Linux to Windows, I can then play it in Windows in two ways:
Case #1) Using FFPlay
Case #2) Using AJA Decoder

In both cases, the Linux out.avi files plays fine in Windows using both 'play' methods. 

Also, by running in Windows:

ffmpeg -f lavfi -i testsrc -t 10 -vcodec r10k out.avi

In windows. I get a out.avi that is EXACTLY the same as I do in Linux.

So yes, they are consistent. 

Hopefully that answers your question?

> > Since the "-vcodec r10k" is a little 'r' I was 
> > expecting a "r10k" (Little Endian) video file.
> Nearly all users would find it extremely annoying if 
> this command line would suddenly produce different 
> output.

So the CODEC_NAME in "-vcodec CODEC_NAME" is NOT case sensitive? If it's NOT case sensative, then yes I could see that anyoing users. However, if "CODEC_NAME" is case sensitive then it would be nice if "-vcodec r10k" means r10k (Little Endian) and "-vcodec R10k" means R10k (Big Edian). I don't see that as extremely annoying since there really are 2 different codec formats: r10k and R10k. If CODEC_NAME is NOT case sensitive, then yes I suppose there is no way to distinguish between r10k and R10k using "-vcodec CODEC_NAME". 

> > > > So the question I have is if there will be a fix 
> > > > put in place to have FFmpeg write r10k (Little 
> > > > Endian)? Too hard to do? Or?
> > > 
> > > Useless?
> > > Or don't you agree?
> > 
> > No, it would not be useless for me. I have a lot of 
> > r10k (Little Endian) video files. I suppose it's a 
> > "nice" to have. It would make things consistent that 
> > FFmpeg can Input and Ouput both R10k and r10k. I 
> > then have a way to convert from r10k to FFV1 and back 
> > to the original r10k when needed.
> Why can't you simply convert to R10k?

Two points: 

1) I can convert to R10k. However, If I am to use FFMpeg, then that seems like my only option since FFmpeg won't output r10k. It means I can NEVER go back to r10k though once I convert to FFV1 using FFmpeg.  

2) I can convert from r10k to FFV1, but again, how do I PROVE that r10k files are converted correctly to FFV1? With v210, for example I could convert from v210 to FFV1 and then back to v210 and verify that the conversion was correct. I can't do this with r10k. And since I can't do that with FFmpeg, how do I prove that the r10k is converted to FFV1 is converted correctly?  

> Or do you mean the file above does not play with 
> applications that are not FFmpeg-based? In this 
> case, I would like to find out why.

It seems to work on the small r10k test files. I'd like to try on BIG r10k files to see how it does. So, I still need to test your fixes more to really confirm. I want to be certain. 



> Carl Eugen
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user

More information about the ffmpeg-user mailing list