[GRASS-SVN] r56628 - grass/branches/develbranch_6/lib/ogsf
svn_grass at osgeo.org
svn_grass at osgeo.org
Fri Jun 7 02:11:25 PDT 2013
Author: hamish
Date: 2013-06-07 02:11:25 -0700 (Fri, 07 Jun 2013)
New Revision: 56628
Modified:
grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c
Log:
tweaks to get it working on Ubuntu/10.04 (#1423)
Modified: grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c
===================================================================
--- grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c 2013-06-07 09:09:10 UTC (rev 56627)
+++ grass/branches/develbranch_6/lib/ogsf/gsd_img_mpeg.c 2013-06-07 09:11:25 UTC (rev 56628)
@@ -263,7 +263,11 @@
av_rescale_q(c->coded_frame->pts, c->time_base,
st->time_base);
if (c->coded_frame->key_frame)
+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52, 32, 0)
+ pkt.flags |= PKT_FLAG_KEY;
+#else
pkt.flags |= AV_PKT_FLAG_KEY;
+#endif
pkt.stream_index = st->index;
pkt.data = video_outbuf;
pkt.size = out_size;
@@ -335,7 +339,11 @@
#endif
if (!fmt) {
G_warning(_("Unable to deduce output format from file extension: using MPEG"));
+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52, 32, 0)
+ fmt = guess_format("mpeg", NULL, NULL);
+#else
fmt = av_guess_format("mpeg", NULL, NULL);
+#endif
}
if (!fmt) {
G_warning(_("Unable to find suitable output format"));
More information about the grass-commit
mailing list