Duration of recorded video

Pmisters

New Member
We use stream recording and got a problem with video duration.
Stream recording starts with REST API command and finishes with client disconnection. As result, we have the file, ex: owner867-1630910657093-1630910849519-72ECC6B6-2D16-4B98-A2ED-073E273D3A30.mp4. That means it should be 1630910849519 - 1630910657093 = 192.426s length.
But ffprobe shows duration: 00:03:11.27 = 191.27s. Why video file is shorter for more than 1 sec?

File template: {streamName}-{startTimeMillis}-{endTimeMillis}-{mediaSessionId}

Tnx
 

Max

Administrator
Staff member
Good day.
File template: {streamName}-{startTimeMillis}-{endTimeMillis}-{mediaSessionId}
You are using server clock time in recording file name template. This time does not correspont to stream recording duration, it only shows server clock value on recording startup and file closing.
You can use {duration} template item which shows recording duration in milliseconds based on stream timestamps.
 
Top