Hi.
I am developing a general purpose video encoding application. Encoder used with CBR (constant bit rate) option. It’
s important.
But artifacts appear on dynamic video scenes after encoding.
I provide screenshots of the video after encoding that I receive after running the example and the original video.
I followed these steps
# take h264 bitstream from mp4 container
ffmpeg -i design.mp4 -vcodec copy -an -bsf:v h264_mp4toannexb design.h264
# take decoded raw file
tegra_multimedia_api/samples/00_video_decode/video_decode H264 --disable-rendering -o design.raw design.h264
# encode raw file
tegra_multimedia_api/samples/01_video_encode/video_encode design.raw 3840 2160 H264 design_new.h264 -rc cbr --max-perf
What other options can you customize? What can you advise for setting up the encoder to encode such dynamic scenes.
My release version
# R32 (release), REVISION: 2.3, GCID: 17644089, BOARD: t186ref, EABI: aarch64, DATE: Tue Nov 5 21:48:17 UTC 2019
Hi,
The setting looks strange. Bitrate is 23Mbps and virtual buffer size is 56Mbps. You may try virtual buffer size = bitrate/framerate. And 23Mbps may be small for 4K. Please try 40Mbps.
Hi,
The scene looks complex and I think 40Mbps may not be enough. However, there is trade-off between video quality and bitrate. In general, 40Mbps should be good for most ordinary scenes.