Gstreamer mpph264enc bitrate control

Hi guys,
i am using gstreamer with rockchip’s mpph264enc encoder, and i am unable to control resulting bitrate (bps)
i found out following parameters
bps : Target BPS (0 = auto calculate)
flags: readable, writable
Unsigned Integer. Range: 0 - 2147483647 Default: 0
bps-max : Max BPS (0 = auto calculate)
flags: readable, writable
Unsigned Integer. Range: 0 - 2147483647 Default: 0
bps-min : Min BPS (0 = auto calculate)
flags: readable, writable
Unsigned Integer. Range: 0 - 2147483647 Default: 0

however setting
bps to 4000000 (aka 4mbps) does not have an effect, and resulting bitrate is still around 8-10mbps

i tried bps-max, but no help

@amazingfate could you please help?

PS i am using ppa:liujianfeng1994/rockchip-multimedia

I’ve played a bit with the gstreamer encoder (1080p@30fps) and you control the bit rate with:

bps=2000000 bps-max=4000000 rc-mode=vbr

But, reading here and there the recommended bitrate for 4k is:

4K 3840x2160 8,000-14,000 kbps 192kbps 48kHz 25/30 h.264 High 1 Second 0-2 Seconds AAC-LC Stereo

Maybe the encoder for 4k “auto-adjust” for best performance. Try that and see what you get.

1 Like