Log in

View Full Version : 10-bit 4:2:2 realtime 4K encoding codecs


zcream
5th December 2013, 00:42
I am setting up a project with 2x 3K cameras connected to a Quad core i7 laptop.
This thread will summarize my attempts to encode the video in realtime with no dropouts.

Thus far, the only codecs that support realtime encoding are -
x264 lossless Hi422P with 10-bit

Cineform 4:2:2 10-bit High

FFV1 4:2:2 10-bit

Blue_MiSfit
5th December 2013, 05:06
You better have a fast disk array :devil:

kolak
6th December 2013, 15:11
I am setting up a project with 2x 3K cameras connected to a Quad core i7 laptop.
This thread will summarize my attempts to encode the video in realtime with no dropouts.

Thus far, the only codecs that support realtime encoding are -
x264 lossless Hi422P with 10-bit

Cineform 4:2:2 10-bit High

FFV1 4:2:2 10-bit

4K Cineform realtime decoding/encoding can be done on i3 1.5GHz- it's extremely fast codec.


ffv1 is interesting, but not sure how fast is latest 1.3 version?

zcream
8th December 2013, 00:38
Is that the free version of Cineform ?
The Gopro-Cineform Studio ?

kolak
15th December 2013, 00:02
Yes- it's the same code. CF is veeery fast.
Free version does not support encoding of HD+ frame size. For 4K you need any of the paid version.

zcream
17th December 2013, 11:44
@kolak
Any idea if 12-bit RGB is supported by ffv1 ? And have you tried lz4 compression in 12-bit RGB mode ?

PNG supports lz4 but its only for 8-bit and 16-bit mode. And the extra 4 bits are a waste.

koliva
18th December 2013, 12:06
Do we have somewhere a comparison study between these codec when encoding 4K?
I am also at the beginning of a similar project. Are you only interested in lossless encoding?

raffriff42
18th December 2013, 15:20
(Is there some reason you don't attach SSDs directly to the cameras? Reliability would be 100x greater.)

What have your results been, so far? Here are some of mine, with ffmpeg (my test was not 3K x2, but results should give *some* idea of relative speeds)
DNXHD yuv422p10 38 fps

PRORES yuv422p10 10 fps

FFV1 yuv420p 14 fps
FFV1 yuv420p10 8 fps

zcream
19th December 2013, 00:07
@raffriff42
The cameras only have a USB3 connector so it is powered and the data is read off with a laptop. The data rate is the problem - here are data rate for a single camera. I have 2x
Options for data rate with uncompressed RAW -

2048 x 1080 x 12bit, 60fps (199MB/s, binning, full sensor)
3120 x 1754 x 12bit, 25fps (205MB/s, windowed)
3200 x 1800 x 12bit, 24fps (207MB/s, windowed)
3584 x 2016 x 8bit, 25fps (181MB/s, windowed)
3728 x 2096 x 8bit, 24fps (188MB/s, windowed but only very slightly of course)

Did you try ffv1 with AC ? That seems really slow for ffv1

foxyshadis
19th December 2013, 00:44
BTW, extra bits are never wasted if they're zeroed out. By converting to 12 bit and then back to 16 bit (without dithering) before lz4 you shouldn't have any waste compared to true 12-bit. The overhead of the conversions shouldn't be too high if you use an optimized routine.

raffriff42
19th December 2013, 01:19
I was under the impression that FFV1 was not optimized for speed, but for compression ratio. Cineform and DNxHD seem most likely to to the job for you.

Hiritsuki
20th December 2013, 15:53
I have try the HDCLUB's demo the past month.
It's from EDIUS 7 is 10bit 422 AVI to 10bit UYVY AVI and for x264 10bit
maybe source is Epic Red 3840x2160.

kolak
20th December 2013, 22:42
(Is there some reason you don't attach SSDs directly to the cameras? Reliability would be 100x greater.)

What have your results been, so far? Here are some of mine, with ffmpeg (my test was not 3K x2, but results should give *some* idea of relative speeds)
DNXHD yuv422p10 38 fps

PRORES yuv422p10 10 fps

FFV1 yuv420p 14 fps
FFV1 yuv420p10 8 fps


Your ProRes speed looks low. Also you have not specified system spec etc. DNxHD doesn't support HD+ frame sizes.

As I said- i5 2GHz+ and you should be fine for 4K 30fps realtime encoding.

18fps on U9400 (Core2 Duo laptop CPU) when encoding from v210 HD to CF in Vdub (SSD disk)

kolak
20th December 2013, 22:58
@kolak
Any idea if 12-bit RGB is supported by ffv1 ? And have you tried lz4 compression in 12-bit RGB mode ?

PNG supports lz4 but its only for 8-bit and 16-bit mode. And the extra 4 bits are a waste.

gbrp10le, gbrp12le work fine, but 16bit RGB is not supported.
16bit YUV and 16bit YUV with Alpha are supported.

kolak
20th December 2013, 23:00
Do we have somewhere a comparison study between these codec when encoding 4K?
I am also at the beginning of a similar project. Are you only interested in lossless encoding?

I can tell you that nothing will come close to Cineform, specially if you need 8bit+ support.
For 8bit UTVideo is faaaaaaast, but data will be big as it's lossless codec.