diff options
author | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2010-07-11 07:35:00 +0000 |
---|---|---|
committer | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2010-07-11 07:35:00 +0000 |
commit | e1d7c8831cf6dddddb8e151a673e89016d7b10db (patch) | |
tree | 49852530bc45ea8d3acd66d8850c33c602caf93c /libavcodec/avcodec.h | |
parent | c426562cbfbe24f3b37ba98b80c128dbcc1b7cc8 (diff) | |
download | ffmpeg-e1d7c8831cf6dddddb8e151a673e89016d7b10db.tar.gz |
Add avsubtitle_free function.
Originally committed as revision 24185 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r-- | libavcodec/avcodec.h | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index 05c96e8e56..475d9b5f03 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -30,7 +30,7 @@ #include "libavutil/avutil.h" #define LIBAVCODEC_VERSION_MAJOR 52 -#define LIBAVCODEC_VERSION_MINOR 81 +#define LIBAVCODEC_VERSION_MINOR 82 #define LIBAVCODEC_VERSION_MICRO 0 #define LIBAVCODEC_VERSION_INT AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \ @@ -3548,13 +3548,22 @@ attribute_deprecated int avcodec_decode_subtitle(AVCodecContext *avctx, AVSubtit * due to a potentially very different allocation pattern. * * @param avctx the codec context - * @param[out] sub The AVSubtitle in which the decoded subtitle will be stored. + * @param[out] sub The AVSubtitle in which the decoded subtitle will be stored, must be + freed with avsubtitle_free if *got_sub_ptr is set. * @param[in,out] got_sub_ptr Zero if no subtitle could be decompressed, otherwise, it is nonzero. * @param[in] avpkt The input AVPacket containing the input buffer. */ int avcodec_decode_subtitle2(AVCodecContext *avctx, AVSubtitle *sub, int *got_sub_ptr, AVPacket *avpkt); + +/** + * Frees all allocated data in the given subtitle struct. + * + * @param sub AVSubtitle to free. + */ +void avsubtitle_free(AVSubtitle *sub); + int avcodec_parse_frame(AVCodecContext *avctx, uint8_t **pdata, int *data_size_ptr, uint8_t *buf, int buf_size); |