ossrs / srs

SRS is a simple, high-efficiency, real-time video server supporting RTMP, WebRTC, HLS, HTTP-FLV, SRT, MPEG-DASH, and GB28181.

Home Page:https://ossrs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

The mp4 file generated by the DVR gives an error when played with the native Windows 10 player.

slhchinatelecom opened this issue · comments

Description
Using DVR mp4 configuration, generate mp4, playback on Windows, the player reports an error.

Description
Please describe the issue you encountered.

1. SRS Version: srs 3.0 -a7

Test command:
./objs/srs -c conf/dvr.mp4.conf

Push stream
./ffmpeg -y -i /home/shilh/sample_h264_300kbit.mp4 -c copy -f flv rtmp://127.0.0.1:1935/live/test

The generated mp4 file can be played using Windows 10 Media Player.

Adding an edit box to the video track can solve the issue.
srs_kernel_mp4.cpp line 5777

        SrsMp4EditBox* edts = new SrsMp4EditBox();
        trak->set_edts(edts);

        SrsMp4EditListBox* elst = new SrsMp4EditListBox();
        edts->set_elst(elst);
        elst->version = 0;

TRANS_BY_GPT3

SRS 3 encountered the same issue

TRANS_BY_GPT3

Great, let me see how to merge it.

TRANS_BY_GPT3

Fixed by ab5ddd2