mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-25 00:32:31 +00:00
avcodec/electronicarts: decode framerate
Reviewed-by: Peter Ross <pross@xvid.org>
This commit is contained in:
parent
f44353cfb6
commit
53d0f9afb4
@ -198,6 +198,10 @@ static int process_audio_header_elements(AVFormatContext *s)
|
|||||||
av_log(s, AV_LOG_DEBUG, "end of header block reached\n");
|
av_log(s, AV_LOG_DEBUG, "end of header block reached\n");
|
||||||
in_header = 0;
|
in_header = 0;
|
||||||
break;
|
break;
|
||||||
|
case 0x1B:
|
||||||
|
ea->video.time_base = (AVRational) {1, read_arbitrary(pb)};
|
||||||
|
av_log(s, AV_LOG_DEBUG, "Setting framerate to %u\n", ea->video.time_base.den);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
av_log(s, AV_LOG_DEBUG,
|
av_log(s, AV_LOG_DEBUG,
|
||||||
"header element 0x%02x set to 0x%08"PRIx32"\n",
|
"header element 0x%02x set to 0x%08"PRIx32"\n",
|
||||||
@ -325,6 +329,7 @@ static void process_video_header_mdec(AVFormatContext *s, VideoProperties *video
|
|||||||
avio_skip(pb, 4);
|
avio_skip(pb, 4);
|
||||||
video->width = avio_rl16(pb);
|
video->width = avio_rl16(pb);
|
||||||
video->height = avio_rl16(pb);
|
video->height = avio_rl16(pb);
|
||||||
|
if (!video->time_base.num)
|
||||||
video->time_base = (AVRational) { 1, 15 };
|
video->time_base = (AVRational) { 1, 15 };
|
||||||
video->codec = AV_CODEC_ID_MDEC;
|
video->codec = AV_CODEC_ID_MDEC;
|
||||||
}
|
}
|
||||||
@ -427,11 +432,13 @@ static int process_ea_header(AVFormatContext *s)
|
|||||||
case pQGT_TAG:
|
case pQGT_TAG:
|
||||||
case TGQs_TAG:
|
case TGQs_TAG:
|
||||||
ea->video.codec = AV_CODEC_ID_TGQ;
|
ea->video.codec = AV_CODEC_ID_TGQ;
|
||||||
|
if (!ea->video.time_base.num)
|
||||||
ea->video.time_base = (AVRational) { 1, 15 };
|
ea->video.time_base = (AVRational) { 1, 15 };
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case pIQT_TAG:
|
case pIQT_TAG:
|
||||||
ea->video.codec = AV_CODEC_ID_TQI;
|
ea->video.codec = AV_CODEC_ID_TQI;
|
||||||
|
if (!ea->video.time_base.num)
|
||||||
ea->video.time_base = (AVRational) { 1, 15 };
|
ea->video.time_base = (AVRational) { 1, 15 };
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user