summaryrefslogtreecommitdiff
path: root/libavformat/format.c
diff options
context:
space:
mode:
authorAnshul Maheshwari <anshul.ffmpeg@gmail.com>2015-01-16 02:00:23 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-01-16 02:24:08 +0100
commita47c9331ef13c4af01de582f159ac6e59fe990ed (patch)
treeac62741a5228b4490c1e802c630a940d087080d8 /libavformat/format.c
parentba97cf2c4562b60fbef89103b61516891e31845e (diff)
avformat: Improve data streams/codec support
This adds data codec/stream handling where previously there was only audio/video/subtitles Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/format.c')
-rw-r--r--libavformat/format.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/format.c b/libavformat/format.c
index 97f5657141..fa94b7d3b5 100644
--- a/libavformat/format.c
+++ b/libavformat/format.c
@@ -151,6 +151,8 @@ enum AVCodecID av_guess_codec(AVOutputFormat *fmt, const char *short_name,
return fmt->audio_codec;
else if (type == AVMEDIA_TYPE_SUBTITLE)
return fmt->subtitle_codec;
+ else if (type == AVMEDIA_TYPE_DATA)
+ return fmt->data_codec;
else
return AV_CODEC_ID_NONE;
}