avformat/mxfdec: use both body_sid and track_number to find the track of a packet
authorMarton Balint <cus@passwd.hu>
Tue, 6 Feb 2018 21:41:16 +0000 (22:41 +0100)
committerMarton Balint <cus@passwd.hu>
Thu, 1 Mar 2018 21:03:53 +0000 (22:03 +0100)
commit9492bb58eeea474158f9c523fd77395629117b57
treec0b92b8560abce8627622e97780941aec476c89a
parent9ec3e61fc37ae0cdd4bae2ba609b34424251e367
avformat/mxfdec: use both body_sid and track_number to find the track of a packet

In order to do that we have to parse the EssenceContainerData and assign the
proper body_sid and index_sid to the tracks from the corresponding source
packages.

This fixes packets returned in the wrong stream for some OP1-b files.

Based on a patch by Alex Mogurenko from https://github.com/da8eat/FFmpeg

Reference: http://mogurenko.com/2018/01/02/mxf-op1b-ffmpeg-part1/

Signed-off-by: Marton Balint <cus@passwd.hu>
libavformat/mxfdec.c