[GRASS-SVN] r52979 - grass/branches/develbranch_6/lib/ogsf
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Aug 29 06:38:58 PDT 2012
Author: neteler
Date: 2012-08-29 06:38:58 -0700 (Wed, 29 Aug 2012)
New Revision: 52979
Modified:
grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c
Log:
support for more recent FFMPEG lib versions (fixes #1423)
Modified: grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c
===================================================================
--- grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c 2012-08-29 13:38:38 UTC (rev 52978)
+++ grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c 2012-08-29 13:38:58 UTC (rev 52979)
@@ -66,7 +66,7 @@
c = st->codec;
c->codec_id = codec_id;
- c->codec_type = CODEC_TYPE_VIDEO;
+ c->codec_type = AVMEDIA_TYPE_VIDEO;
/* put sample parameters */
c->bit_rate = 400000;
@@ -215,7 +215,7 @@
av_init_packet(&pkt);
- pkt.flags |= PKT_FLAG_KEY;
+ pkt.flags |= AV_PKT_FLAG_KEY;
pkt.stream_index = st->index;
pkt.data = (uint8_t *) picture;
pkt.size = sizeof(AVPicture);
@@ -236,7 +236,7 @@
av_rescale_q(c->coded_frame->pts, c->time_base,
st->time_base);
if (c->coded_frame->key_frame)
- pkt.flags |= PKT_FLAG_KEY;
+ pkt.flags |= AV_PKT_FLAG_KEY;
pkt.stream_index = st->index;
pkt.data = video_outbuf;
pkt.size = out_size;
@@ -301,10 +301,10 @@
av_register_all();
/* auto detect the output format from the name. default is mpeg. */
- fmt = guess_format(NULL, filename, NULL);
+ fmt = av_guess_format(NULL, filename, NULL);
if (!fmt) {
G_warning(_("Unable to deduce output format from file extension: using MPEG"));
- fmt = guess_format("mpeg", NULL, NULL);
+ fmt = av_guess_format("mpeg", NULL, NULL);
}
if (!fmt) {
G_warning(_("Unable to find suitable output format"));
@@ -312,7 +312,7 @@
}
/* allocate the output media context */
- oc = av_alloc_format_context();
+ oc = avformat_alloc_context();
if (!oc) {
G_warning(_("Out of memory"));
return (-1);
More information about the grass-commit
mailing list