Commit 6be378a7 authored by bcoudurier's avatar bcoudurier

always export videostreams

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@7452 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 87216115
...@@ -792,25 +792,20 @@ static int swf_read_header(AVFormatContext *s, AVFormatParameters *ap) ...@@ -792,25 +792,20 @@ static int swf_read_header(AVFormatContext *s, AVFormatParameters *ap)
return AVERROR_IO; return AVERROR_IO;
} }
if ( tag == TAG_VIDEOSTREAM && !vst) { if ( tag == TAG_VIDEOSTREAM && !vst) {
int codec_id;
swf->ch_id = get_le16(pb); swf->ch_id = get_le16(pb);
get_le16(pb); get_le16(pb);
get_le16(pb); get_le16(pb);
get_le16(pb); get_le16(pb);
get_byte(pb); get_byte(pb);
/* Check for FLV1 */ /* Check for FLV1 */
codec_id = codec_get_id(swf_codec_tags, get_byte(pb));
if ( codec_id ) {
vst = av_new_stream(s, 0); vst = av_new_stream(s, 0);
av_set_pts_info(vst, 24, 1, 1000); /* 24 bit pts in ms */ av_set_pts_info(vst, 24, 1, 1000); /* 24 bit pts in ms */
vst->codec->codec_type = CODEC_TYPE_VIDEO; vst->codec->codec_type = CODEC_TYPE_VIDEO;
vst->codec->codec_id = codec_id; vst->codec->codec_id = codec_get_id(swf_codec_tags, get_byte(pb));
if ( swf->samples_per_frame ) { if (swf->samples_per_frame) {
vst->codec->time_base.den = 1000. / swf->ms_per_frame; vst->codec->time_base.den = 1000. / swf->ms_per_frame;
vst->codec->time_base.num = 1; vst->codec->time_base.num = 1;
} }
}
} else if ( ( tag == TAG_STREAMHEAD || tag == TAG_STREAMHEAD2 ) && !ast) { } else if ( ( tag == TAG_STREAMHEAD || tag == TAG_STREAMHEAD2 ) && !ast) {
/* streaming found */ /* streaming found */
get_byte(pb); get_byte(pb);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment