We want to test the encoding latency. Using the existing sample code, we ran the following command:
/usr/src/jetson_multimedia_api/samples/01_video_encode# ./video_encode input.yuv 1920 1080 H264 out.264 -hpt 1 -ifi 50 -br 2000000 -rc cbr --max-perf -fps 60 1 --stats
The latency shown here indicates an average latency of 34.698ms, with a maximum reaching 70.959ms. This latency is significant. Is there a way to reduce it to below 10ms?
Thanks for your reply.
Hi,
What is your JP/BSP version?
Thanks
The JP and BSP version is:
apt-cache show nvidia-jetpack | grep Version
Version: 6.2.1+b38
Version: 6.2+b77
Version: 6.1+b123
cat /etc/nv_tegra_release
R36 (release), REVISION: 4.3, GCID: 38968081, BOARD: generic, EABI: aarch64, DATE: Wed Jan 8 01:49:37 UTC 2025
KERNEL_VARIANT: oot
TARGET_USERSPACE_LIB_DIR=nvidia
TARGET_USERSPACE_LIB_DIR_PATH=usr/lib/aarch64-linux-gnu/nvidia
Hi,
Thanks for your info.
Could you provide the intput.yuv
or the command to generate input.yuv
for us to test in our side?
Thanks
Hi,
You can decode this H.265 file into YUV, thereby obtaining the original YUV source,
thanks
car_source.zip (22.8 MB)
Hi,
Please check the properties for low latency:
HW encoding and decoding speed - #4 by DaneLLL
These are applicable for both gstreamer and jetson_multimedia_api. You may set poc-type=2. And suggest set -hpt 0. Furthermore, you can enable slice encoding and output buffers in slices.