Log in

View Full Version : Any way to set maximum AU/frame size in x264


benwaggoner
12th March 2014, 19:52
I was playing around with a device that appears to have a maximum limit on the size of an AU (not NALU) it can decode in some circumstances. So, if a frame size is over a maximum value, badness ensues.

Is there any way to specify a maximum frame size in x264? I know I could always set the --vbv-maxsize to the maximum frame size, but that would hurt quality obviously.

Or is there an implicit maximum frame size in x264 based on Profile @ Level or something? I was trying to make that big a frame with some test content and never got one more than 650 KB for High Level 4.0 when encoding a few hours of content, even using the max allowed VBV of 31250. But that doesn't mean it's never possible. Unless it isn't for some reason.

Ah, there are so many more ways to implement a decoder wrong than there are right...

Guest
12th March 2014, 19:59
Ah, there are so many more ways to implement a decoder wrong than there are right... Encoder?

nevcairiel
12th March 2014, 20:28
I think he was referring to the broken decoder on this particular device.. :)

Dark Shikari
12th March 2014, 20:36
x264 implements MinCR internally based on level.

Guest
12th March 2014, 22:08
I think he was referring to the broken decoder on this particular device.. :) Got it, thanks.

benwaggoner
12th March 2014, 22:28
x264 implements MinCR internally based on level.
So, what can I expect as maximum size of an individual frame for, say Level 4.0?

Dark Shikari
12th March 2014, 22:30
So, what can I expect as maximum size of an individual frame for, say Level 4.0?
level 4.0 -> mincr = 4, so 1/4 of the uncompressed size of a frame.

benwaggoner
12th March 2014, 22:42
level 4.0 -> mincr = 4, so 1/4 of the uncompressed size of a frame.
So, for 1920x1080 8-bit 4:2:0, that'd be 1920x1080x1.5 (1.5 bytes per pixel), thus 3.11 MB?

Dark Shikari
12th March 2014, 23:45
So, for 1920x1080 8-bit 4:2:0, that'd be 1920x1080x1.5 (1.5 bytes per pixel), thus 3.11 MB?Yes, so the MinCR limit would be 777600 bytes.