aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-04-05 03:23:43 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-04-05 03:23:47 +0200
commit7a5537fd3fd06f71c077ef06467149390ed491ea (patch)
tree42c73d0d1a1bacd480c4e7bd36a647a1f4b19585 /libavformat
parenta2c6a99ba56a8c4c4b5efb7474002de10e67bb06 (diff)
parent90d93eeb386fc3cfd8669ad8007feefd372767e9 (diff)
downloadffmpeg-7a5537fd3fd06f71c077ef06467149390ed491ea.tar.gz
Merge remote-tracking branch 'cehoyos/master'
* cehoyos/master: Allow .y as extension for image2. Show stream number when warning about stream without start time. Force gif aspect ratio multiplication to 64bit. Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/gif.c5
-rw-r--r--libavformat/img2enc.c2
-rw-r--r--libavformat/utils.c2
3 files changed, 5 insertions, 4 deletions
diff --git a/libavformat/gif.c b/libavformat/gif.c
index 68320c6f23..e817121440 100644
--- a/libavformat/gif.c
+++ b/libavformat/gif.c
@@ -33,10 +33,11 @@ static int gif_image_write_header(AVFormatContext *s, int width, int height,
{
AVIOContext *pb = s->pb;
AVRational sar = s->streams[0]->codec->sample_aspect_ratio;
- int i, aspect = 0;
+ int i;
+ int64_t aspect = 0;
if (sar.num > 0 && sar.den > 0) {
- aspect = sar.num * 64 / sar.den - 15;
+ aspect = sar.num * 64LL / sar.den - 15;
if (aspect < 0 || aspect > 255)
aspect = 0;
}
diff --git a/libavformat/img2enc.c b/libavformat/img2enc.c
index 684ed1441e..37dfbecce3 100644
--- a/libavformat/img2enc.c
+++ b/libavformat/img2enc.c
@@ -194,7 +194,7 @@ AVOutputFormat ff_image2_muxer = {
.long_name = NULL_IF_CONFIG_SMALL("image2 sequence"),
.extensions = "bmp,dpx,jls,jpeg,jpg,ljpg,pam,pbm,pcx,pgm,pgmyuv,png,"
"ppm,sgi,tga,tif,tiff,jp2,j2c,j2k,xwd,sun,ras,rs,im1,im8,im24,"
- "sunras,webp,xbm,xface,pix",
+ "sunras,webp,xbm,xface,pix,y",
.priv_data_size = sizeof(VideoMuxData),
.video_codec = AV_CODEC_ID_MJPEG,
.write_header = write_header,
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 10508f6ab7..207501a296 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2451,7 +2451,7 @@ static void estimate_timings_from_pts(AVFormatContext *ic, int64_t old_offset)
st->first_dts == AV_NOPTS_VALUE &&
st->codec->codec_type != AVMEDIA_TYPE_UNKNOWN)
av_log(st->codec, AV_LOG_WARNING,
- "start time is not set in estimate_timings_from_pts\n");
+ "start time for stream %d is not set in estimate_timings_from_pts\n", i);
if (st->parser) {
av_parser_close(st->parser);