mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +02:00
avidec: Enable full parsing for potencoder mpeg1/2
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
63e8fc4d8f
commit
a079ed63d3
@ -365,6 +365,7 @@ static int avi_read_header(AVFormatContext *s)
|
|||||||
int amv_file_format=0;
|
int amv_file_format=0;
|
||||||
uint64_t list_end = 0;
|
uint64_t list_end = 0;
|
||||||
int ret;
|
int ret;
|
||||||
|
AVDictionaryEntry *dict_entry;
|
||||||
|
|
||||||
avi->stream_index= -1;
|
avi->stream_index= -1;
|
||||||
|
|
||||||
@ -802,6 +803,16 @@ static int avi_read_header(AVFormatContext *s)
|
|||||||
avi_load_index(s);
|
avi_load_index(s);
|
||||||
avi->index_loaded |= 1;
|
avi->index_loaded |= 1;
|
||||||
avi->non_interleaved |= guess_ni_flag(s) | (s->flags & AVFMT_FLAG_SORT_DTS);
|
avi->non_interleaved |= guess_ni_flag(s) | (s->flags & AVFMT_FLAG_SORT_DTS);
|
||||||
|
|
||||||
|
dict_entry = av_dict_get(s->metadata, "ISFT", NULL, 0);
|
||||||
|
if (dict_entry && !strcmp(dict_entry->value, "PotEncoder"))
|
||||||
|
for (i=0; i<s->nb_streams; i++) {
|
||||||
|
AVStream *st = s->streams[i];
|
||||||
|
if ( st->codec->codec_id == AV_CODEC_ID_MPEG1VIDEO
|
||||||
|
|| st->codec->codec_id == AV_CODEC_ID_MPEG2VIDEO)
|
||||||
|
st->need_parsing = AVSTREAM_PARSE_FULL;
|
||||||
|
}
|
||||||
|
|
||||||
for(i=0; i<s->nb_streams; i++){
|
for(i=0; i<s->nb_streams; i++){
|
||||||
AVStream *st = s->streams[i];
|
AVStream *st = s->streams[i];
|
||||||
if(st->nb_index_entries)
|
if(st->nb_index_entries)
|
||||||
|
Loading…
Reference in New Issue
Block a user