Media (Intel® Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools like Intel® oneAPI Video Processing Library and Intel® Media SDK
Announcements
The Intel Media SDK project is no longer active. For continued support and access to new features, Intel Media SDK users are encouraged to read the transition guide on upgrading from Intel® Media SDK to Intel® Video Processing Library (VPL), and to move to VPL as soon as possible.
For more information, see the VPL website.

ffmpeg: mpegts muxer: Non-monotonous DTS in output stream when using b-frames

Haris_Z_
Beginner
2,368 Views

When encoding using main or high profile with b-frames, and output via mepgts muxer and udp, I get somewhat frequently (around each 10-30 seconds) warnings about "Non-monotonous DTS in output stream" from the mpegts muxer. It seems that (though only sometimes and not on all b-frames, because there are plenty of b-frames in the stream), that the b-frames are somehow "out of order" regarding DTS.

An example log of 1 such occurence with 3 frames "affected":
2017/11/14 13:15:34 [mpegts @ 0x4609da0] Non-monotonous DTS in output stream 0:2; previous: 973677600, current: 973645200; changing to 973677601. This may result in incorrect timestamps in the output file.
2017/11/14 13:15:34 [mpegts @ 0x4609da0] Non-monotonous DTS in output stream 0:2; previous: 973677601, current: 973648800; changing to 973677602. This may result in incorrect timestamps in the output file.
2017/11/14 13:15:34 [mpegts @ 0x4609da0] Non-monotonous DTS in output stream 0:2; previous: 973677602, current: 973652400; changing to 973677603. This may result in incorrect timestamps in the output file.

1 occurence can have 1 or more frames that are in sequence, up to max b-frames setting for encoder.


I am pretty unsure if this is a real problem as I was unable to link that to any obvious picture artifacts in the player when playing such stream. Regardless, I would like to understand if this is a known issue and if it is ffmpeg or Media SDK caused.
Please help with any indication on where to look for the cause of this.

Using ffmpeg version n3.2.8

python sys_analyzer_linux.py
--------------------------
Hardware readiness checks:
--------------------------
 [ OK ] Processor name: Intel(R) Core(TM) i7-4860EQ CPU @ 1.80GHz
--------------------------
OS readiness checks:
--------------------------
 [ OK ] GPU visible to OS
 [ OK ] Linux distro suitable for Media Server Studio 2016 Gold
--------------------------
Media Server Studio Install:
--------------------------
 [ ERROR ] user not in video group.  Add with usermod -a -G video {user}
 [ OK ] libva.so.1 found
 [ OK ] vainfo reports valid codec entry points
 [ OK ] /dev/dri/renderD128 connects to Intel i915
--------------------------
Component Smoke Tests:
--------------------------
 [ OK ] Media SDK HW API level:1.17
 [ OK ] Media SDK SW API level:1.17
 [ OK ] OpenCL check:platform:Intel(R) OpenCL GPU OK CPU OK

 

0 Kudos
3 Replies
Mohammad_T_1
Beginner
2,368 Views

Hello Haris,

I seems problem is with ffmpeg. Try using ffmpeg 3.2 or later.

0 Kudos
Haris_Z_
Beginner
2,368 Views

Hi,
I am using ffmpeg version n3.2.8
Later versions of ffmpeg seem to have problems with SDK 2106, which I have to use because all runs on Haswell HW.

0 Kudos
Maxym_D_Intel
Employee
2,368 Views

it would be important to see used ffmpeg command line and to have input sample.

is this only one CPU SKU you are focusing at?

0 Kudos
Reply