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

Unified Diff: source/patched-ffmpeg-mt/libavformat/img2.c

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/img2.c
===================================================================
--- source/patched-ffmpeg-mt/libavformat/img2.c (revision 65184)
+++ source/patched-ffmpeg-mt/libavformat/img2.c (working copy)
@@ -171,7 +171,7 @@
}
-static int image_probe(AVProbeData *p)
+static int read_probe(AVProbeData *p)
{
if (p->filename && av_str2id(img_tags, p->filename)) {
if (av_filename_number_test(p->filename))
@@ -186,7 +186,7 @@
return av_str2id(img_tags, filename);
}
-static int img_read_header(AVFormatContext *s1, AVFormatParameters *ap)
+static int read_header(AVFormatContext *s1, AVFormatParameters *ap)
{
VideoData *s = s1->priv_data;
int first_index, last_index;
@@ -249,7 +249,7 @@
return 0;
}
-static int img_read_packet(AVFormatContext *s1, AVPacket *pkt)
+static int read_packet(AVFormatContext *s1, AVPacket *pkt)
{
VideoData *s = s1->priv_data;
char filename[1024];
@@ -320,7 +320,7 @@
/******************************************************/
/* image output */
-static int img_write_header(AVFormatContext *s)
+static int write_header(AVFormatContext *s)
{
VideoData *img = s->priv_data;
@@ -336,7 +336,7 @@
return 0;
}
-static int img_write_packet(AVFormatContext *s, AVPacket *pkt)
+static int write_packet(AVFormatContext *s, AVPacket *pkt)
{
VideoData *img = s->priv_data;
ByteIOContext *pb[3];
@@ -413,56 +413,47 @@
/* input */
#if CONFIG_IMAGE2_DEMUXER
AVInputFormat image2_demuxer = {
- "image2",
- NULL_IF_CONFIG_SMALL("image2 sequence"),
- sizeof(VideoData),
- image_probe,
- img_read_header,
- img_read_packet,
- NULL,
- NULL,
- NULL,
- AVFMT_NOFILE,
+ .name = "image2",
+ .long_name = NULL_IF_CONFIG_SMALL("image2 sequence"),
+ .priv_data_size = sizeof(VideoData),
+ .read_probe = read_probe,
+ .read_header = read_header,
+ .read_packet = read_packet,
+ .flags = AVFMT_NOFILE,
};
#endif
#if CONFIG_IMAGE2PIPE_DEMUXER
AVInputFormat image2pipe_demuxer = {
- "image2pipe",
- NULL_IF_CONFIG_SMALL("piped image2 sequence"),
- sizeof(VideoData),
- NULL, /* no probe */
- img_read_header,
- img_read_packet,
+ .name = "image2pipe",
+ .long_name = NULL_IF_CONFIG_SMALL("piped image2 sequence"),
+ .priv_data_size = sizeof(VideoData),
+ .read_header = read_header,
+ .read_packet = read_packet,
};
#endif
/* output */
#if CONFIG_IMAGE2_MUXER
AVOutputFormat image2_muxer = {
- "image2",
- NULL_IF_CONFIG_SMALL("image2 sequence"),
- "",
- "bmp,jpeg,jpg,ljpg,pam,pbm,pcx,pgm,pgmyuv,png,ppm,sgi,tga,tif,tiff,jp2",
- sizeof(VideoData),
- CODEC_ID_NONE,
- CODEC_ID_MJPEG,
- img_write_header,
- img_write_packet,
- NULL,
- .flags= AVFMT_NOTIMESTAMPS | AVFMT_NODIMENSIONS | AVFMT_NOFILE
+ .name = "image2",
+ .long_name = NULL_IF_CONFIG_SMALL("image2 sequence"),
+ .extensions = "bmp,jpeg,jpg,ljpg,pam,pbm,pcx,pgm,pgmyuv,png,"
+ "ppm,sgi,tga,tif,tiff,jp2",
+ .priv_data_size = sizeof(VideoData),
+ .video_codec = CODEC_ID_MJPEG,
+ .write_header = write_header,
+ .write_packet = write_packet,
+ .flags = AVFMT_NOTIMESTAMPS | AVFMT_NODIMENSIONS | AVFMT_NOFILE
};
#endif
#if CONFIG_IMAGE2PIPE_MUXER
AVOutputFormat image2pipe_muxer = {
- "image2pipe",
- NULL_IF_CONFIG_SMALL("piped image2 sequence"),
- "",
- "",
- sizeof(VideoData),
- CODEC_ID_NONE,
- CODEC_ID_MJPEG,
- img_write_header,
- img_write_packet,
- .flags= AVFMT_NOTIMESTAMPS | AVFMT_NODIMENSIONS
+ .name = "image2pipe",
+ .long_name = NULL_IF_CONFIG_SMALL("piped image2 sequence"),
+ .priv_data_size = sizeof(VideoData),
+ .video_codec = CODEC_ID_MJPEG,
+ .write_header = write_header,
+ .write_packet = write_packet,
+ .flags = AVFMT_NOTIMESTAMPS | AVFMT_NODIMENSIONS
};
#endif

Powered by Google App Engine
This is Rietveld 408576698