Please share your location. Are you in Europe or North America?
[Out of context]
Could you go to NVIDIA.com and then click ‘Contact Us’ in the footer. This will ensure that you get the local version of the link.
[Out of context]
I checked L4T 32.1 on a TX2. There is definitely an improvement, but it seems to me that that VUI timing parameters are not absolutely correct, the resolution seems to be 0.25 frame/sec:
- FPS setting is 29000/1000 -> num_units_in_tick : 1, time_scale : 58 (29 FPS)
- FPS setting is 29100/1000 -> num_units_in_tick : 4, time_scale : 232 (29 FPS)
- FPS setting is 29200/1000 -> num_units_in_tick : 4, time_scale : 232 (29 FPS)
- FPS setting is 29300/1000 -> num_units_in_tick : 4, time_scale : 234 (29.25 FPS)
- FPS setting is 29400/1000 -> num_units_in_tick : 4, time_scale : 234 (29.25 FPS)
- FPS setting is 29500/1000 -> num_units_in_tick : 4, time_scale : 236 (29.5 FPS)
- FPS setting is 29600/1000 -> num_units_in_tick : 4, time_scale : 236 (29.5 FPS)
Also, the encoded file size (thus bitrate) only changes with the above resolution, e.g. the encoded file size is the same for 29000/1000 and 29100/1000 setting, so it seems that the effect is also present is the encoder’s bitrate calculation.
Frame rates below 1 (e.g. 500/1000) are handled incorrectly, the result is 30 FPS - both in VUI parameters and in file size.
Is this a known issue?
Forgot to mention: the above is valid for H.264.
For H.265 I did not check VUI, but the file size issue is present, so I estimate that bitrate calculation is the same for both encoders.
For r32.1, you may check https://elinux.org/Jetson_AGX_Xavier/r32.1_patch
I replaced libnvtvmr.so, does not seem to solve the issue.
Please try to run 01_video_encode:
video_encode bunny_i420.bin 1920 1080 H264 bunny.h264 --insert-aud --insert-spspps-idr --insert-vui -fps 29970 1000
In the resulting H.264 file I have:
num_units_in_tick : 4
time_scale : 238
This is definitely not 29.97 fps.
Please also share frame rate in ffprobe. The command is at
Stream #0:0: Video: h264 (Constrained Baseline), yuv420p(tv, progressive), 1920x1080, 29.75 fps, 29.75 tbr, 1200k tbn, 59.50 tbc
The result looks fine. Should be rounding to 29.75 instead of 29.97. Please try ‘-fps 30000 1001’ and check if it is 29.97.
I tried -fps 30000 1001
It is still 29.75.
BTW, why should be -fps 29970 1000 rounded to 29.75?
Do you have any news regarding the issue?
For backwards compatibility with our older H264 products it is really important for us to have correct VUI timing parameters.
The accuracy is 0.25fps like 29.25, 29.5, 29.75. So it has to be exact 29.97 in your product? Do you also use NVIDIA platforms in older products?
Yes, we have to be exact. Otherwise the elementary stream is incorrect.
And with this accuracy there are standard framerates which cannot be set correctly, e.g. 29.97, 59.94. Moreover, in our product we have the option for framerate decimation - in those cases it gets even worse. Due to the incorrect framerate parameter handling the resulting encoder bitrate is quite off from the input paramerter we set.
The older products does not use NVIDIA platform, but the VUI framerate issue is general: it can be seen on every playback platform, e.g. all PC decoders I tried (including ffmpeg, VLC, MPC-HC) displays incorrect elementary stream FPS because the VUI is incorrect.
Could you please give me an info which version is the most probable?
- Do you have a fix for 32.1?
- Do you plan to have a fix for 32.1?
- Do you plan to fix it in a later release?
I really need an answer to be able to decide how to go on with our development. It is really urgent, please respond.
We are checking it. If you need to prioritize the issue, please contact us to have further cooperation.
Please try attachment. It is verified by running following commands:
$ ./video_encode a.yuv 1920 1080 H264 out.h264 --insert-aud --insert-spspps-idr --insert-vui -fps 29970 1000 $ ffprobe ./out.h264
Would like to reiterate that you can always contact us to seek for direct technical support.
r32_1_libtegrav4l2.zip (71.5 KB)
Thank you very much for the fast fix. My results:
- 29970/1000 is ok
- 59940/1000 is ok
- 59940/2000 is ok
- For other dividers (59940/3000, 59940/4000, 29970/2000) the resolution of the frame rate is still 0.25 FPS.
- For frame rates below 1 FPS VUI is still set to 30 FPS.
As you advised, I will contact directly using the above link.