Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Unified Diff: source/patched-ffmpeg-mt/libavformat/avformat.h

Issue 4533003: patched ffmpeg nov 2 (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/ffmpeg/
Patch Set: '' Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: source/patched-ffmpeg-mt/libavformat/avformat.h
===================================================================
--- source/patched-ffmpeg-mt/libavformat/avformat.h (revision 65184)
+++ source/patched-ffmpeg-mt/libavformat/avformat.h (working copy)
@@ -22,7 +22,7 @@
#define AVFORMAT_AVFORMAT_H
#define LIBAVFORMAT_VERSION_MAJOR 52
-#define LIBAVFORMAT_VERSION_MINOR 80
+#define LIBAVFORMAT_VERSION_MINOR 84
#define LIBAVFORMAT_VERSION_MICRO 0
#define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \
@@ -40,20 +40,50 @@
* They may change, break or disappear at any time.
*/
#ifndef FF_API_MAX_STREAMS
-#define FF_API_MAX_STREAMS (LIBAVFORMAT_VERSION_MAJOR < 53)
+#define FF_API_MAX_STREAMS (LIBAVFORMAT_VERSION_MAJOR < 53)
#endif
#ifndef FF_API_OLD_METADATA
-#define FF_API_OLD_METADATA (LIBAVFORMAT_VERSION_MAJOR < 53)
+#define FF_API_OLD_METADATA (LIBAVFORMAT_VERSION_MAJOR < 53)
#endif
#ifndef FF_API_URL_CLASS
-#define FF_API_URL_CLASS (LIBAVFORMAT_VERSION_MAJOR >= 53)
+#define FF_API_URL_CLASS (LIBAVFORMAT_VERSION_MAJOR >= 53)
#endif
#ifndef FF_API_URL_RESETBUF
-#define FF_API_URL_RESETBUF (LIBAVFORMAT_VERSION_MAJOR < 53)
+#define FF_API_URL_RESETBUF (LIBAVFORMAT_VERSION_MAJOR < 53)
#endif
#ifndef FF_API_REGISTER_PROTOCOL
-#define FF_API_REGISTER_PROTOCOL (LIBAVFORMAT_VERSION_MAJOR < 53)
+#define FF_API_REGISTER_PROTOCOL (LIBAVFORMAT_VERSION_MAJOR < 53)
#endif
+#ifndef FF_API_GUESS_FORMAT
+#define FF_API_GUESS_FORMAT (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_UDP_GET_FILE
+#define FF_API_UDP_GET_FILE (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_URL_SPLIT
+#define FF_API_URL_SPLIT (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_ALLOC_FORMAT_CONTEXT
+#define FF_API_ALLOC_FORMAT_CONTEXT (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_PARSE_FRAME_PARAM
+#define FF_API_PARSE_FRAME_PARAM (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_READ_SEEK
+#define FF_API_READ_SEEK (LIBAVFORMAT_VERSION_MAJOR < 54)
+#endif
+#ifndef FF_API_LAVF_UNUSED
+#define FF_API_LAVF_UNUSED (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_PARAMETERS_CODEC_ID
+#define FF_API_PARAMETERS_CODEC_ID (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_FIRST_FORMAT
+#define FF_API_FIRST_FORMAT (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
+#ifndef FF_API_SYMVER
+#define FF_API_SYMVER (LIBAVFORMAT_VERSION_MAJOR < 53)
+#endif
/**
* I return the LIBAVFORMAT_VERSION_INT constant. You got
@@ -107,10 +137,9 @@
* sorting will have '-sort' appended. E.g. artist="The Beatles",
* artist-sort="Beatles, The".
*
- * 4. Tag names are normally exported exactly as stored in the container to
- * allow lossless remuxing to the same format. For container-independent
- * handling of metadata, av_metadata_conv() can convert it to ffmpeg generic
- * format. Follows a list of generic tag names:
+ * 4. Demuxers attempt to export metadata in a generic format, however tags
+ * with no generic equivalents are left as they are stored in the container.
+ * Follows a list of generic tag names:
*
* album -- name of the set this work belongs to
* album_artist -- main creator of the set/album, if different from artist.
@@ -147,7 +176,9 @@
}AVMetadataTag;
typedef struct AVMetadata AVMetadata;
+#if FF_API_OLD_METADATA
typedef struct AVMetadataConv AVMetadataConv;
+#endif
/**
* Get a metadata element with matching key.
@@ -186,16 +217,13 @@
*/
int av_metadata_set2(AVMetadata **pm, const char *key, const char *value, int flags);
+#if FF_API_OLD_METADATA
/**
- * Convert all the metadata sets from ctx according to the source and
- * destination conversion tables. If one of the tables is NULL, then
- * tags are converted to/from ffmpeg generic tag names.
- *
- * @param d_conv destination tags format conversion table
- * @param s_conv source tags format conversion table
+ * This function is provided for compatibility reason and currently does nothing.
*/
-void av_metadata_conv(struct AVFormatContext *ctx, const AVMetadataConv *d_conv,
- const AVMetadataConv *s_conv);
+attribute_deprecated void av_metadata_conv(struct AVFormatContext *ctx, const AVMetadataConv *d_conv,
+ const AVMetadataConv *s_conv);
+#endif
/**
* Free all the memory allocated for an AVMetadata struct.
@@ -261,9 +289,9 @@
unsigned int initial_pause:1; /**< Do not begin to play the stream
immediately (RTSP only). */
unsigned int prealloced_context:1;
-#if LIBAVFORMAT_VERSION_INT < (53<<16)
- enum CodecID video_codec_id;
- enum CodecID audio_codec_id;
+#if FF_API_PARAMETERS_CODEC_ID
+ attribute_deprecated enum CodecID video_codec_id;
+ attribute_deprecated enum CodecID audio_codec_id;
#endif
} AVFormatParameters;
@@ -319,7 +347,9 @@
enum CodecID subtitle_codec; /**< default subtitle codec */
+#if FF_API_OLD_METADATA
const AVMetadataConv *metadata_conv;
+#endif
/* private fields */
struct AVOutputFormat *next;
@@ -377,7 +407,7 @@
*/
int (*read_close)(struct AVFormatContext *);
-#if LIBAVFORMAT_VERSION_MAJOR < 53
+#if FF_API_READ_SEEK
/**
* Seek to a given timestamp relative to the frames in
* stream component stream_index.
@@ -386,8 +416,8 @@
* match is available.
* @return >= 0 on success (but not necessarily the new offset)
*/
- int (*read_seek)(struct AVFormatContext *,
- int stream_index, int64_t timestamp, int flags);
+ attribute_deprecated int (*read_seek)(struct AVFormatContext *,
+ int stream_index, int64_t timestamp, int flags);
#endif
/**
* Gets the next timestamp in stream[stream_index].time_base units.
@@ -435,7 +465,9 @@
*/
int (*read_seek2)(struct AVFormatContext *s, int stream_index, int64_t min_ts, int64_t ts, int64_t max_ts, int flags);
+#if FF_API_OLD_METADATA
const AVMetadataConv *metadata_conv;
+#endif
/* private fields */
struct AVInputFormat *next;
@@ -538,7 +570,7 @@
int64_t duration;
#if FF_API_OLD_METADATA
- char language[4]; /**< ISO 639-2/B 3-letter language code (empty string if undefined) */
+ attribute_deprecated char language[4]; /**< ISO 639-2/B 3-letter language code (empty string if undefined) */
#endif
/* av_read_frame() support */
@@ -556,12 +588,12 @@
int64_t nb_frames; ///< number of frames in this stream if known or 0
-#if LIBAVFORMAT_VERSION_INT < (53<<16)
- int64_t unused[4+1];
+#if FF_API_LAVF_UNUSED
+ attribute_deprecated int64_t unused[4+1];
#endif
#if FF_API_OLD_METADATA
- char *filename; /**< source filename of the stream */
+ attribute_deprecated char *filename; /**< source filename of the stream */
#endif
int disposition; /**< AV_DISPOSITION_* bit field */
@@ -642,8 +674,8 @@
typedef struct AVProgram {
int id;
#if FF_API_OLD_METADATA
- char *provider_name; ///< network name for DVB streams
- char *name; ///< service name for DVB streams
+ attribute_deprecated char *provider_name; ///< network name for DVB streams
+ attribute_deprecated char *name; ///< service name for DVB streams
#endif
int flags;
enum AVDiscard discard; ///< selects which program to discard and which to feed to the caller
@@ -660,7 +692,7 @@
AVRational time_base; ///< time base in which the start/end timestamps are specified
int64_t start, end; ///< chapter start/end time in time_base units
#if FF_API_OLD_METADATA
- char *title; ///< chapter title
+ attribute_deprecated char *title; ///< chapter title
#endif
AVMetadata *metadata;
} AVChapter;
@@ -693,14 +725,14 @@
/* stream info */
int64_t timestamp;
#if FF_API_OLD_METADATA
- char title[512];
- char author[512];
- char copyright[512];
- char comment[512];
- char album[512];
- int year; /**< ID3 year, 0 if none */
- int track; /**< track number, 0 if none */
- char genre[32]; /**< ID3 genre */
+ attribute_deprecated char title[512];
+ attribute_deprecated char author[512];
+ attribute_deprecated char copyright[512];
+ attribute_deprecated char comment[512];
+ attribute_deprecated char album[512];
+ attribute_deprecated int year; /**< ID3 year, 0 if none */
+ attribute_deprecated int track; /**< track number, 0 if none */
+ attribute_deprecated char genre[32]; /**< ID3 genre */
#endif
int ctx_flags; /**< Format-specific flags, see AVFMTCTX_xx */
@@ -741,7 +773,7 @@
/* av_read_frame() support */
AVStream *cur_st;
-#if LIBAVFORMAT_VERSION_INT < (53<<16)
+#if FF_API_LAVF_UNUSED
const uint8_t *cur_ptr_deprecated;
int cur_len_deprecated;
AVPacket cur_pkt_deprecated;
@@ -871,9 +903,9 @@
struct AVPacketList *next;
} AVPacketList;
-#if LIBAVFORMAT_VERSION_INT < (53<<16)
-extern AVInputFormat *first_iformat;
-extern AVOutputFormat *first_oformat;
+#if FF_API_FIRST_FORMAT
+attribute_deprecated extern AVInputFormat *first_iformat;
+attribute_deprecated extern AVOutputFormat *first_oformat;
#endif
/**
@@ -898,7 +930,7 @@
/* utils.c */
void av_register_input_format(AVInputFormat *format);
void av_register_output_format(AVOutputFormat *format);
-#if LIBAVFORMAT_VERSION_MAJOR < 53
+#if FF_API_GUESS_FORMAT
attribute_deprecated AVOutputFormat *guess_stream_format(const char *short_name,
const char *filename,
const char *mime_type);
@@ -1062,7 +1094,7 @@
int buf_size,
AVFormatParameters *ap);
-#if LIBAVFORMAT_VERSION_MAJOR < 53
+#if FF_API_ALLOC_FORMAT_CONTEXT
/**
* @deprecated Use avformat_alloc_context() instead.
*/
@@ -1413,7 +1445,7 @@
const char *url,
int is_output);
-#if LIBAVFORMAT_VERSION_MAJOR < 53
+#if FF_API_PARSE_FRAME_PARAM
/**
* Parse width and height out of string str.
* @deprecated Use av_parse_video_frame_size instead.

Powered by Google App Engine
This is Rietveld 408576698