When using FFmpeg to remux a libde265 generated mkv file to mp4 it generate an invalid output file.

The simple command the I use and works for all other MKV files is the following:

 ffmpeg -i source.mkv -c:v copy -tag:v hvc1  output.mp4

By trying to analyze the generated file with ffprobe I see the following error:
[extract_extradata @ 0x7fd9abc176c0] Invalid NAL unit 0, skipping.
[hevc @ 0x7fd9ac00b000] Invalid NAL unit 0, skipping.
[extract_extradata @ 0x7fd9abc176c0] No start code is found.
tos-1720x720-cfg01.mp4: Invalid data found when processing input

Any other files generated using other h265 library works correctly when muxed.

Any hint?

FFMpeg remux issue for libde265 generated mkv files
This is a GitHub Issue
repo:libde265
owner:strukturag
Title : FFMpeg remux issue for libde265 generated mkv files
Issue date:

--- start body ---
When using FFmpeg to remux a libde265 generated mkv file to mp4 it generate an invalid output file.

The simple command the I use and works for all other MKV files is the following:

 ffmpeg -i source.mkv -c:v copy -tag:v hvc1  output.mp4

By trying to analyze the generated file with ffprobe I see the following error:
[extract_extradata @ 0x7fd9abc176c0] Invalid NAL unit 0, skipping.
[hevc @ 0x7fd9ac00b000] Invalid NAL unit 0, skipping.
[extract_extradata @ 0x7fd9abc176c0] No start code is found.
tos-1720x720-cfg01.mp4: Invalid data found when processing input

Any other files generated using other h265 library works correctly when muxed.

Any hint?

--- end body ---
