Multiplex a HEVC-Video into a MPEG-Transportstream

2019-09-07 13:04发布

I would like to multiplex a HEVC coded video into a MPEG-Transportstream.

I have a Video coded with the x265 Encoder.

x265 raw.y4m --output coded.hevc

I want to multiplex this Video into an MPEG Transportstream. I tried it among other things this way:

ffmpeg -fflags +genpts -i coded.hevc -c:v copy -f mpegts transportstream.ts 

Unfortunately this error message shows up and the transportstream.ts is empty.

[mpegts @ 0x1fa76a0] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
[mpegts @ 0x1fa76a0] first pts value must be set
av_interleaved_write_frame(): Invalid data found when processing input

For my purpose, it is necessary to do the two steps separate. Could you help me please to find out the correct parameters to multiplex the Video?

Thanks in advance.

1条回答
Fickle 薄情
2楼-- · 2019-09-07 13:44

A two-step process works:

ffmpeg -i coded.hevc -c copy coded.mp4

ffmpeg -i coded.mp4 -c:v copy transportstream.ts 
查看更多
登录 后发表回答