mirror of
https://github.com/mpv-player/mpv.git
synced 2026-10-29 07:06:59 +08:00
demux: remove falsification of ff-index
The `ff-index` is just a index of in the track order as seen by lavf. However, there are many cases where tracks are not related to lavf, when it's not used or there are virtual tracks addded like DOVI EL track or merged image tile grid. Don't conjure `ff-index` out of nothing. Some scripts may be confused when this index does not much ffmpeg. Even though it has always stated in docs. Fixes #18244
This commit is contained in:
@@ -1003,9 +1003,6 @@ static void demux_add_sh_stream_locked(struct demux_internal *in,
|
||||
if (!sh->codec->codec)
|
||||
sh->codec->codec = "";
|
||||
|
||||
if (sh->ff_index < 0)
|
||||
sh->ff_index = sh->index;
|
||||
|
||||
MP_TARRAY_APPEND(in, in->streams, in->num_streams, sh);
|
||||
mp_assert(in->streams[sh->index] == sh);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user