aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/avformat.h
diff options
context:
space:
mode:
authorAurelien Jacobs <aurel@gnuage.org>2009-02-28 23:34:16 +0000
committerAurelien Jacobs <aurel@gnuage.org>2009-02-28 23:34:16 +0000
commitf610a9f284e8319907962b1be4d93051444bcf90 (patch)
tree4506f9a564abf59c590f3873676c322b266b77df /libavformat/avformat.h
parentefd8c1f64d3b1673021162210e0b265bcd5ea4c8 (diff)
downloadffmpeg-f610a9f284e8319907962b1be4d93051444bcf90.tar.gz
add a metadata conversion API
Originally committed as revision 17670 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/avformat.h')
-rw-r--r--libavformat/avformat.h18
1 files changed, 16 insertions, 2 deletions
diff --git a/libavformat/avformat.h b/libavformat/avformat.h
index cc20fbb884..94764f3875 100644
--- a/libavformat/avformat.h
+++ b/libavformat/avformat.h
@@ -46,6 +46,8 @@ unsigned avformat_version(void);
#include "avio.h"
+struct AVFormatContext;
+
/*
* Public Metadata API.
@@ -77,6 +79,7 @@ typedef struct {
}AVMetadataTag;
typedef struct AVMetadata AVMetadata;
+typedef struct AVMetadataConv AVMetadataConv;
/**
* Gets a metadata element with matching key.
@@ -96,6 +99,15 @@ av_metadata_get(AVMetadata *m, const char *key, const AVMetadataTag *prev, int f
int av_metadata_set(AVMetadata **pm, const char *key, const char *value);
/**
+ * Convert all the metadata sets from ctx according to the source and
+ * destination conversion tables.
+ * @param d_conv destination tags format conversion table
+ * @param s_conv source tags format conversion table
+ */
+void av_metadata_conv(struct AVFormatContext *ctx,const AVMetadataConv *d_conv,
+ const AVMetadataConv *s_conv);
+
+/**
* Frees all the memory allocated for an AVMetadata struct.
*/
void av_metadata_free(AVMetadata **m);
@@ -220,8 +232,6 @@ typedef struct AVFrac {
struct AVCodecTag;
-struct AVFormatContext;
-
/** This structure contains the data a format has to probe a file. */
typedef struct AVProbeData {
const char *filename;
@@ -299,6 +309,8 @@ typedef struct AVOutputFormat {
enum CodecID subtitle_codec; /**< default subtitle codec */
+ AVMetadataConv *metadata_conv;
+
/* private fields */
struct AVOutputFormat *next;
} AVOutputFormat;
@@ -378,6 +390,8 @@ typedef struct AVInputFormat {
*/
int (*read_seek2)(struct AVFormatContext *s, int stream_index, int64_t min_ts, int64_t ts, int64_t max_ts, int flags);
+ AVMetadataConv *metadata_conv;
+
/* private fields */
struct AVInputFormat *next;
} AVInputFormat;